I don't really understand your context, but if you want to iterate through nested hashes, it is usually easier to use the
values function, rather than the
keys function. Just a short example on how easy it is:
use strict;
use warnings;
my %hash = (
A => { F => 1, G => "3A", H => 5 },
B => { F => 1, G => "3B", H => 5 },
C => { F => 1, G => "3C", H => 5 },
D => { F => 1, G => "3D", H => 5 },
E => { F => 1, G => "3E", H => 5 },
);
print "$_->{G} " for (values %hash);
which prints:
3A 3D 3C 3E 3B
Or, if you want to go through the values of the inner hashes:
print join " ", map {values %{$_}, "-"} values %hash;
Output:
5 1 3A - 5 1 3D - 5 1 3C - 5 1 3E - 5 1 3B -