### The JAPH at the end of the tunnel

by jimt (Chaplain)
 on Dec 14, 2006 at 16:18 UTC Need Help??

I haven't done a JAPH in forever. Here's a very long and animated one.
```#!/usr/bin/perl
while(\$t++<\$FOUR*\$FOUR+\$EIGHT){\$b[\$_]=[map{\$"}@a]for@a;\$xs=\$z>23?(\$z-=
+\$FOUR,\$xs)
:\$z-\$FOUR;\$u=int(@a/\$THREE-\$xs);for\$x(\$u..\$u+\$xs*\$THREE+\$TWO) {\$b[\$_]-
+>[\$x]=\$x==
\$_?'\\':\$x==@a-\$_?'/':\$b[\$_]->[\$x]for(\$u..\$u+\$TWO+\$THREE*\$xs)}\$i=0;whi
+le(\$z-\$i>0
){\$s=\$z-(\$i+=\$FOUR);\$u=int(@a/\$THREE-\$s); \$s*=\$THREE;\$us=\$u+\$s;for\$x(\$
+u..10+\$us-
9){for\$y(\$u..\$u+\$TWO+\$s){;\$b[\$y]->[\$x]=' 'if\$t>=31&&\$s<\$EIGHT;\$b[\$y]->
+[\$x]=(\$y==
\$u||\$y-\$TWO==\$us)&&( \$x==\$u||\$x-\$TWO==\$us)?'+':\$y==\$u||\$y==\$us+\$TWO?'-
+':\$x==\$u||
\$x-\$TWO==\$us?'|':\$b[\$y]->[\$x]};}BEGIN{\$FOUR=5;\$THREE=\$FOUR-3;\$TWO=\$FOU
+R/5;@a=0..
\$TWO+42-\$FOUR;\$EIGHT=\$FOUR*2}}if(@a-\$FOUR+\$TWO==\$t){\$TEN=\$FOUR+\$FOUR+\$
+TWO;\$THREE
;@w=map{[split//]}qw(Just Another Perl Hacker);\$y=\$x=42-\$FOUR**\$THREE;
+for\$w(@w){
\$y++;\$b[\$y]->[\$x+\$_]=\$w->[\$_]for(0..\$#\$w)}}print"\ec",map{@{\$b[\$_]},\$/
+}@a;select
\$&,\$&,\$&,\$TWO/10;\$z++}

Replies are listed 'Best First'.
Re: The JAPH at the end of the tunnel
by liverpole (Monsignor) on Dec 14, 2006 at 16:30 UTC
++jimt,

A very nice visual effect ... I like it!

s''(q.S:\$/9=(T1';s;(..)(..);\$..=substr+crypt(\$1,\$2),2,3;eg;print\$..\$/
Re: The JAPH at the end of the tunnel
by sgt (Deacon) on Dec 16, 2006 at 23:26 UTC

just great! and saved for personal enjoyment. There was a thread today about the syntactic superiority of haskell: I wonder if there is a lambdacamel out there who can show us the version in haskell of your program... and then we will compare the fun ratio in doing both...

cheers --stephan
Re: The JAPH at the end of the tunnel
by teamster_jr (Curate) on Dec 14, 2006 at 23:44 UTC
sweet!

"jimt, you've switched off your targeting computer"

er, that's what i thought of anyway :)

a

Re: The JAPH at the end of the tunnel
by wulvrine (Friar) on Dec 18, 2006 at 14:06 UTC
Wow great job! ++!
Brought me back to the days of walking down the corridor in Wizardry!

s&&VALKYRIE &&& print \$_^q|!4 =+;' *|

Create A New User
Node Status?
node history
Node Type: obfuscated [id://589855]
Approved by chargrill
Front-paged by liverpole
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (1)
As of 2018-05-22 21:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?
World peace can best be achieved by:

Results (166 votes). Check out past polls.

Notices?