[Perl-pad-users] Tublimng Lrettes
Status: Alpha
Brought to you by:
thiloplanz
From: Thilo P. <thi...@us...> - 2003-09-16 03:08:05
|
Oyak, tihs is olny midlly fyunn, but since evnyroee is wnriitg lkie this tyoad, I susoppe I hvae to foollw suit. There is eevn a blosxom pilgun now to julbme words aulacitamolty and you can find the PerlPad snppiet taht preudcod this mail bewol. Tliho #! perl-pad -a foreach my $word (@F){ if ($word =~ /^(.)(.+)(.)/){ my ($a, $b, $c ) = ($1, $2, $3); $b = reverse $b if rand() < 0.5; $b = "$1$3$2$4" if rand() < 0.8 and $b =~ /^(.)(.)(.+)(.)$/; $b = "$4$1$3$2" if rand() < 0.8 and $b =~ /^(.+)(.)(.)(.)$/; $word = "$a$b$c"; } print "$word "; } |