in reply to JAPH randomness

It works fine on perl 5.8.1-RC3/Mac OS X 10.3/PPC G4 and perl 5.8.4/Debian Sarge/AMD K6 MMX, so endianness does not appear to be an issue. It fails on perl 5.6.1/Red Hat Linux 7.3/Intel 486DX because the string passed to srand() is not entirely numeric and therefore is interpreted as 0. The following modification works around this:
$"='314747"7"84561"12"277057"10"53708"12"2466"25"'; sub _{$;.=chr(rand(24)+64)}while($"){$"=~s/(.*?)"// ;srand$1;rand(24)for(1.."$\"");$"=~s/.*?"//;_()for( 1..5)}$;=~y/BV/ ./;$;=~s/\w+/\u\L$&/g;print$;.$/

Replies are listed 'Best First'.
Re^2: JAPH randomness
by awwaiid (Friar) on Jan 31, 2005 at 16:39 UTC

    Cool, thanks. I didn't even expect it to break because of that... It should really break (and require significant alteration of $') if someone were to use a perl which had a different rand() library call compiled in.