in reply to Please Help with Hashes
what doesn't work for you? maybe strict and warnings will give you some hints?#!/usr/bin/perl -w use strict; my %h1 = ( "key1","value1","Key2", "value2" ); my %h2 = ( "Key1","value1","key2", "value2" ); my %hoh = ( "key1" => \%h1, "key2" => \%h2 ); foreach my $key (keys %hoh){ my $innerHashRef = $hoh{$key}; foreach my $innerHashKey (keys %$innerHashRef){ print "Inner Key: $innerHashKey\n"; } } #prints: Inner Key: Key2 Inner Key: key1 Inner Key: Key1 Inner Key: key2
~Particle *accelerates*
|
|---|