Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

(Guildenstern: Hash Slice?) RE: Populating a Hash: Can someone help me to understand?

by Guildenstern (Deacon)
on Sep 19, 2000 at 20:14 UTC ( #33118=note: print w/replies, xml ) Need Help??


in reply to Populating a Hash: Can someone help me to understand?

Why can't you just use a hash slice? Like this:@hash{@keys} = @values;I imagine this would require that both arrays have equal numbers of values, but then any other kind of hash population would likely assume that as well.
Update: Okay, so I missed the post by japhy. At least merlyn had the common courtesy to explain why he --'d it.

Guildenstern
Negaterd character class uber alles!
  • Comment on (Guildenstern: Hash Slice?) RE: Populating a Hash: Can someone help me to understand?
  • Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (10)
As of 2020-05-29 20:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (171 votes). Check out past polls.

    Notices?