Greetings,

this is my first japh script - comments welcome. Does it matter if the output is all lowercase or is it better 'style' to write every word with a capital letter?

Thanks,
Bort.

#!/usr/bin/perl open ME,$0;rand 42;_(2,4,21,1,29,2,17,1,10,4,21,1,11,4); sub _{map{seek ME,shift,!1;read ME,$c,shift;$a.=$c;}@_;} _(21,1,94,1,29,1,111,1,88,1,12,2);$a=~s,\/(us)r,j$1t,;$a =~s,/p,th,;print $a;

Replies are listed 'Best First'.
Re: just another perl script
by jonadab (Parson) on Mar 08, 2003 at 22:14 UTC

    It prints <q>justMndptherMperlMfnsMer</q> here.

    I had to look up what the third argument to seek does, but I think I see how it's supposed to work. Looks to me like the problem is that you made an assumption about the number of bytes in an end-of-line sequence. You can't do that, if you want it to be portable.


    for(unpack("C*",'GGGG?GGGG?O__\?WccW?{GCw?Wcc{?Wcc~?Wcc{?~cc' .'W?')){$j=$_-63;++$a;for$p(0..7){$h[$p][$a]=$j%2;$j/=2}}for$ p(0..7){for$a(1..45){$_=($h[$p-1][$a])?'#':' ';print}print$/}