Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re^2: Dereferencing array of hashes

by Not_a_Number (Parson)
on Nov 11, 2013 at 20:27 UTC ( #1062050=note: print w/replies, xml ) Need Help??

in reply to Re: Dereferencing array of hashes
in thread Dereferencing array of hashes's not necessary to use a C-style loop here

Indeed. In fact I'd simplify things even further by not using an array index at all:

for my $item ( @AoH ) { for my $key ( keys %$item ) { print "$key => $item->{ $key }\n"; } }

Replies are listed 'Best First'.
Re^3: Dereferencing array of hashes
by Kenosis (Priest) on Nov 11, 2013 at 20:41 UTC

    Oh, this is smart++! Am glad you added this comment!

      Thanks. But Laurent_R beat me to it by a clear 30 seconds minutes. Upvote him instead.

      Update: Yes, obviously, minutes not secconds. Thanks Laurent_R and AnomalousMonk!

        Thanks. But Laurent_R beat me to it by a clear 30 seconds. Upvote him instead.

        I guess you mean 30 minutes, don't you? ;-)

        Thanks for the upvote recommendation anyway. :-)

        Duly noted, but have upvoted you both...

        Clearly, 30 minutes!

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (4)
As of 2016-10-24 02:10 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (302 votes). Check out past polls.