Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: Print elements of hash references

by Happy-the-monk (Monsignor)
on Mar 31, 2012 at 18:37 UTC ( #962790=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Print elements of hash references
in thread Print elements of hash references

push @{$An{$n}->{b}} , $bb[$idx];

let's see, if perldsc did not make it clear enough, maybe perldata and perllol will help a bit further?
Anyway, looking for "references" and Hashes of Hashes (HoH) and Hashes of Arrays (HoA) in the documentation and also on this site may help you along.

What you are doing is pushing onto an array reference that is inside a hash (%An) of hashes the value in position ($idx) of an array (@bb).

I am a little curious though: If you don't know what you are doing, why are you doing it?

To see the results, do try use Data::Dumper;print Dumper \%An;

Cheers, Sören


Comment on Re^3: Print elements of hash references
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (8)
As of 2014-08-22 05:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (147 votes), past polls