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

Re: Simplifying for loop and applying multiple push function

by BrowserUk (Patriarch)
on Dec 14, 2005 at 22:24 UTC ( [id://516791]=note: print w/replies, xml ) Need Help??


in reply to Simplifying for loop and applying multiple push function

In one line with no pushing or cheating :)

@hash{ 'a'..'z' } = 1 .. 26;; 1 while ( $one[@one], $two[@two] ) = each %hash;; print "@one\n@two";; r a x d j y u k h g f t i e n v m s l c p q b z o 18 1 24 4 10 25 21 11 8 7 6 20 9 5 14 22 13 19 12 3 16 17 2 26 15

Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (7)
As of 2024-03-28 09:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found