in reply to Re: When a PERL Hacker Retires
in thread When a PERL Hacker Retires

Ah, that explains it... Here is a patched version that works for me on unix.
@d=(17,103,24, 63,31,106,32,2,45, 90,70, 104,71,2,72,2,81, 96,103,84,104, 84,115,105, 116,2,148,36, 149,113,150, 2,156,88,181, 36,182,2,212 ,36,213,2,242 , 36,243,2,247, 86,271,36,291 ,54,292,2,319, 36,320,2,346,36 ,347,2,350,61, 372,31,396,99,397,2,422,113,423 ,2,448,113,449,2,474,113,497 ,100,498,2,522,81,523,113 ,524,36,525,2,526,2 ,531,65,572,105, 573,2,574, 2,575,2, 583,71,618,93, 619,2,620,2,634, 58,659,90,660,2, 681,69,692,103);for(;$i <=$#d;$i+= 2 ){$c[$d[ $i]]=$d[$i+1]}foreach$c (@c) {if($c){$c+=$c==2?8:11} else{$c=32}print chr($c)} # WHEN A PERL HACKER RETIRES #
notice the slight munging in the second to last line of code... It now prints chr(10) instead of chr(13)

-Blake

Replies are listed 'Best First'.
Re: Re: Re: When a PERL Hacker Retires
by Elliott (Pilgrim) on Oct 11, 2001 at 13:43 UTC
    Doh! Thanks blakem. Now that just leaves Windows folk out in the cold.

    I really should have known better than to use chr for a line ending - even it was 3am when I was coding it.
      Nope! It looks pretty much the same on Windows. Nice work! Too bad you can't color the text to be gold. ;-)
      Actually if you're using Active Perl (and I think Indigo as well, perhaps any Win32 build?) "\n" in outuput is automagically translated to \n\r. Of course you might go ahead just do chr(10).chr(13)...