I finally got around to writing a piece of obfuscated perl. Here is its story.

One of the many subjects I have to do it progamming (in Matlab). I told the teacher (good guy) about Perl and to my shock and horror he had never heard of it. Aha, I'll bring my laptop in (Debian), says I, and show you some: Good he says and why not rewrite today's exercise in Perl for me? No problem says I, and, being the sneaky, underhand little sh*t that I can occasionally be I re-wrote it for him. Here it is, my first ever JAPH:

#! /usr/bin/perl -w use Math::Complex; $zxa=abs(1+(-exp(1)**(i*pi))-(exp((sqrt(9)/3)-sqrt(1))));$xza="vppnabo +vs";$axz=$zxa-((-exp(1)**(i*pi))**(-exp(1)**(i*pi)));$xza=~tr{s\\\r\n +\b\f}{S};$azx=(1*(10**(int(pi-($zxa*2)))));push@zax,$axz;push@zax,$zx +a;$xza =~ tr/A-Za-z/N-ZA-Mn-za-m/;while ($xza=~s/^(.)//){unshift @xaz +, $1;}for ($xaz=1;$xaz<=$azx;++$xaz){$zax=$axz+$zxa;push@zax,$zax;$ax +z=$zxa;$zxa=$zax;}print"\n".(join"",@xaz).":\n".(join" ",@zax)."\n\n" +;

Hope you enjoyed it praying that my typing was correct. I don't think it'll ever be a classic but I like it all the same (It cost me 2 hours work, 1.5 Litres of minty syrup stuff and about half-a-pound of pretzels.) Just for the record I did also write an unobfuscated version but he gets this one first!

Elgon

Update:All typos corrected, so should work fine ... I hope

Replies are listed 'Best First'.
Re: First ever japh: so be nice!
by ImpalaSS (Monk) on Dec 16, 2000 at 00:56 UTC
    Hey, when i went to run it, i got an error. There is a  } missing right after:
    ($xaz=1;$xaz<=$azx;++$xaz){$zax=$axz+$zxa;push@zax,$zax;$axz=$z +ax;$zxa=$zax
    I hope this helps

    Dipul
    Update: Seems like you fixed that problem :)
Re: First ever japh: so be nice!
by myocom (Deacon) on Dec 16, 2000 at 00:59 UTC

    Very nice (though not technically a JAPH). I did have to add a closing brace to get it to run, though...

    Update: What he said. All fixed.
      Re: Typing error...

      Sorry about that: I get my jollies with my Debian laptop whereas the University I'm at is all NT, hence I had to type it in again - not good for accuarcy.

      Thanks, Elgon