
Jasmine
Administrator
Jan 19, 2001, 3:22 PM
Post #1 of 1
(3372 views)
|
How do I process an entire hash?
|
Can't Post
|
|
(From the Perl FAQ) How do I process an entire hash? Use the each() function (see each) if you don't care whether it's sorted: while ( ($key, $value) = each %hash) { print "$key = $value\n"; } If you want it sorted, you'll have to use foreach() on the result of sorting the keys as shown in an earlier question.
|