SamCG has asked for the wisdom of the Perl Monks concerning the following question:
Hi as a sample:
-----------------
s''limp';@p=split '!','n!h!p!';s,m,s,;$s=y;$c=slice @p1;so brutally;d;$n=reverse;$c=$s**$#p;print(''.$c^chop($n))while($c/=$#p)>=1;
Shouldn't this be producing just "f", as the d flag should cause unmatched items to be deleted?C:\>perl -e "$_=alter;tr/this/flip/d;print;" alfer
-----------------
s''limp';@p=split '!','n!h!p!';s,m,s,;$s=y;$c=slice @p1;so brutally;d;$n=reverse;$c=$s**$#p;print(''.$c^chop($n))while($c/=$#p)>=1;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: transliteration d flag not working as expected
by BrowserUk (Patriarch) on Jun 09, 2013 at 11:20 UTC | |
Re: transliteration d flag not working as expected
by hdb (Monsignor) on Jun 09, 2013 at 11:24 UTC | |
Re: transliteration d flag not working as expected
by LanX (Sage) on Jun 09, 2013 at 11:41 UTC | |
by AnomalousMonk (Archbishop) on Jun 09, 2013 at 12:04 UTC | |
by LanX (Sage) on Jun 09, 2013 at 12:29 UTC | |
by AnomalousMonk (Archbishop) on Jun 09, 2013 at 13:14 UTC |
Back to
Seekers of Perl Wisdom