my %hash = ( keya => [a1, b1, [ qw(c1a c1b) ] ], keyb => [a2, b2, [ qw(c2a c2b) ] ], ); foreach my $key (sort keys %hash){ print $hash{$key}[0]; print $hash{$key}[1]; print $hash{$key}[2][0]; print $hash{$key}[2][1]; }
note: don't use a comma inside qw() - it expects just spaces.
In reply to Re: Complex data structure
by fglock
in thread Complex data structure
by neilwatson
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |