Running this:
#!/usr/bin/perl $l="@ARGV"; $l=~s/\W//g; $l=~tr/A-Z/a-z/; foreach$p(p($l)){print"$p\n";} sub p{ my $l=$_[0]; my @a=(); if(length($l)>1){ if((join"",reverse(split//,$l))eq$l){push(@a,$l)} push(@a,p(substr($l,1,length($l)),1)); unless($_[1]){push(@a,p(substr($l,0,length($l)-1),0))}} return@a;}
with "Laetitia Casta" as a command line parameter explains a great deal. ;)
BTW, I just love the way you can obfuscate perl code into complete and utter unreadability with such ease. Saves bandwidth too. Perfect scripting language.
[Wolf550e <3 perl]
No comments:
Post a Comment