Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Diamonds for fun

by LanX (Canon)
on May 04, 2011 at 12:35 UTC ( #902859=note: print w/ replies, xml ) Need Help??


in reply to Diamonds for fun

perl -e'$"="";$x=pop;@x=reverse(1..$x);print " "x($x-$_),"@x[@x[1..$_] +]@x[$x+1-$_..$x]\n"for@x[@x],@x' 9 1 121 12321 1234321 123454321 12345654321 1234567654321 123456787654321 12345678987654321 123456787654321 1234567654321 12345654321 123454321 1234321 12321 121 1

could be shortened!

have fun deobfuscating! :)

Cheers Rolf


Comment on Re: Diamonds for fun
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://902859]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (20)
As of 2015-07-01 17:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (13 votes), past polls