in reply to hash of hashes
Why on earth would you want to do that? For each letter sequence you want the list of numbers that were associated with it. That shouts for a hash of arrays.
In the loop, when you have $lets and $nums, collect the numbers belonging to $lets:
To print the results:push @{ $plates{ $lets} }, $nums;
(Code untested)print "$_ ", join( ', ', @{ $plates{ $_}), "\n" for sort keys %plates;
Anno
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: hash of hashes
by Joost (Canon) on Mar 23, 2007 at 21:46 UTC | |
by volcan (Novice) on Mar 23, 2007 at 22:08 UTC | |
by Anno (Deacon) on Mar 24, 2007 at 08:05 UTC | |
by volcan (Novice) on Mar 25, 2007 at 19:59 UTC |