Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: looking for a perl way to build a hash

by BrowserUk (Patriarch)
on Jul 26, 2013 at 13:55 UTC ( [id://1046518]=note: print w/replies, xml ) Need Help??


in reply to looking for a perl way to build a hash

$str1="a,b,c";; $str2="1,2,3";; @hash{ split ',',$str1 } = split ',', $str2;; pp \%hash;; { a => 1, b => 2, c => 3 }

With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"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://1046518]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (5)
As of 2024-04-20 00:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found