[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

[FWP] Re: PerlOS




Chip Turner wrote:
> 
> Speaking of wasted effort:

I foolishly presumed you meant coder effort...


> @s = ("fate", "anoints", "idle", "coders"); @a = ("kill", "apropos",
> "pico", "ispell");print join(' ', ($s[0]..$a[0])[83813],
> ($s[1]..$a[1])[188889], ($s[2]..$a[2])[123871],
> ($s[3]..$a[3])[52995357]);

I have never experienced such a simultaneous revulsion and delight
in my entire life.  All I can say is -- Brilliant.

'Course, I would probably have written it like this:

print "@{[ map {
  ( (qw(fate anoints idle coders))[$_]
 .. (qw(kill apropos pico ispell))[$_]
 )[ (qw(83813 188889 123871 52995357))[$_] ]
} ( 0 .. 3 ) ]}\n";

to save those space-wasting temporary variables. :-)

John Porter


==== Want to unsubscribe from Fun With Perl?  Well, if you insist...
==== Send email to <fwp-request@technofile.org> with message _body_
====   unsubscribe