in reply to This, too, was wasted on my wife.

I like one liners: print chr($a += $_) foreach qw (74 43 -2 1 -84 65 13 1 5 -12 -3 13 -82 80 -11 13 -6 -76 72 -7 2 8 -6 13); Your wife must be pretty picky -- I liked this one.

Replies are listed 'Best First'.
RE: RE: This, too, was wasted on my wife.
by cciulla (Friar) on May 02, 2000 at 01:47 UTC
    THAT is pretty slick.

    I'm ass-u-me-ing that the "foreach" construct is treated kinda-sorta like a function?

    BTW, my wife thinks that these are the "geekiest" things she's seen me do.

      actually, the "foreach" in the one-liner above is treated as more like my personal fav'rit use of "if", i.e.
      print $line if $line =~ /Perl/;
      e.g. "do this IF that"; similarly, the "foreach" says "do this for each of these." It's with constructs like these that you can tell Perl was designed by a linguist =)
RE: RE: This, too, was wasted on my wife.
by turnstep (Parson) on May 01, 2000 at 19:09 UTC
    Ah, but did your wife? :)