Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?

Re: Golf: Movie style code cracker.

by blokhead (Monsignor)
on Sep 12, 2008 at 19:24 UTC ( #710986=note: print w/replies, xml ) Need Help??

in reply to Golf: Movie style code cracker.

Fun. Here's my interpretation of what a scrolling hacker toy would look like... It's 90 characters.
$n=pop;for(;;){warn$f,map(int rand 10,1..$n),$/;++$i%1e3 or$f.=int ran +d 10 and$n--or last}

You could make it run for >2.5 minutes by ...

Update: Here is another one that fills in the fixed positions not left-to-right, but randomly, to look more Matrix-like. As it gets more and more characters fixed, it slows down to increase the drama (this is me trying to sell a design inefficiency as a feature). It's 124 characters.

On my machine, it looks nice doing 20-digit combinations.


Replies are listed 'Best First'.
Re^2: Golf: Movie style code cracker.
by repellent (Priest) on Sep 14, 2008 at 01:47 UTC
    You're not matching the randomly chosen code C. On your way to decipher C, you would have likely iterated through the "correct" left-digits of C a few times before "locking" in.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2021-09-20 00:10 GMT
Find Nodes?
    Voting Booth?

    No recent polls found