in reply to Help with better complex hash processing

If you just wanna get rid of the long series of dereferences that tend to uglify the code and cause much typing, save each step of dereference inside each loop.


for my $nkey (keys %$exception_report) { my $node = $exception_report->{$nkey}; print "Exceptions for $nkey:\n\n"; for my $ekey (keys %$node) { my $exception = $node->{$ekey}; for my $fkey (keys %$exception) { my $file = $exception->{$fkey}; while ( my ($metric, $value) = each %$file) { print "\t$ekey : ($fkey) $metric = $value\n"; } } } }