Obviously, this code depends on the internal, unspecified implementation of sort. I only tested it on Strawberry Perl 5.14.2 (64 bits); please let me know whether it works anywhere else. Edit: minor code improvements.use strict; use warnings;()= sort{index+0x47,&$a($b)}sub{print&{;pop}}, sort{sub J{$!++&1}[0]}sub{exec''},map{@$_} sort{sub _{[(pop)x((1<<$!-->>47)|1)]}!{()= sort{my$_=$a;$a=_(sub{$_})if!/0/}$a,$b,0}} sort J('rke%ca hlrPe rhetoan tus;J')=~/./g
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: How to (ab)use sort
by moritz (Cardinal) on Apr 17, 2012 at 09:04 UTC | |
by choroba (Cardinal) on Apr 17, 2012 at 09:21 UTC | |
by Grimy (Pilgrim) on Apr 17, 2012 at 09:36 UTC | |
Re: How to (ab)use sort
by biohisham (Priest) on Apr 22, 2012 at 16:33 UTC | |
Re: How to (ab)use sort
by kcott (Archbishop) on Apr 23, 2012 at 00:15 UTC |