Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: array of hashes

by eighty-one (Curate)
on Oct 02, 2008 at 15:19 UTC ( [id://715036]=note: print w/replies, xml ) Need Help??


in reply to array of hashes

First, read How do I post a question effectively? and Writeup Formatting Tips - your question would be much easier to read with >code< tags.

As for your question, I found The Perl hash How-To very informative back when I found hashes & hashrefs confusing. Since children is an array, you should be able to just iterate over it with a foreach and perform any action that needs to be taken on each child, and increment a counter to count. Also, you can refer to an array in scalar context to get a count.

Replies are listed 'Best First'.
Re^2: array of hashes
by fionbarr (Friar) on Oct 02, 2008 at 15:30 UTC
     code it is, sorry, and thanks

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2024-04-24 16:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found