Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Simplifying for loop and applying multiple push function

by serf (Chaplain)
on Dec 14, 2005 at 21:01 UTC ( #516764=note: print w/ replies, xml ) Need Help??


in reply to Simplifying for loop and applying multiple push function

use strict; use warnings; my %hash = ( 1 => 'one', 2 => 'two', 3 => 'three' ); my(@one,@two); while ( my ( $key, $val ) = each %hash ) { push @one, $val; push @two, $key; }


Comment on Re: Simplifying for loop and applying multiple push function
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (10)
As of 2015-07-31 08:51 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 (276 votes), past polls