Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Pushing into a hash of arrays

by Arunbear (Prior)
on Mar 16, 2015 at 17:25 UTC ( [id://1120202]=note: print w/replies, xml ) Need Help??


in reply to Pushing into a hash of arrays

There is a way i.e.
push @{ $directory{owner1} }, $value;
or
push @{ $directory{owner1}{0} }, $value;
if there actually is an intermediate hash with key "0" that holds the array (I'm not sure why you need the intermediate hash).

Updated: D'oh! Added missing commas in code samples (thanks hdb / choroba / davido !)

Replies are listed 'Best First'.
Re^2: Pushing into a hash of arrays
by alberto_zurita (Initiate) on Mar 17, 2015 at 19:51 UTC
    Thanks to all for you answers! ;)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (2)
As of 2024-04-26 01:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found