I've looked at this for a few days but still can't see 'why' I get what I do. Why do @arrays and @seconds not have the same number of elements? Thanks, Mike
{ my %HoAoA = ( a => [ [ qw / aa1 aa2 / ], [ qw / ab1 ab2 / ] ], b => [ [ qw / ba1 ba2 / ], [ qw / bb1 bb2 / ], [ qw / bc1 bc2 / ] ], ); # this gets refs to all arrays my @arrays = map { @{ $HoAoA{$_} } [ 0..$#{ $HoAoA{$_} } ] } keys %HoAoA ; # this only gets the second entry from the last array of each hash entry my @seconds = map { @{ $HoAoA{$_} } [ 0..$#{ $HoAoA{$_} } ]->[1] } keys %HoAoA ; print "\...@arrays = @arrays\n"; print "\...@seconds = @seconds\n"; } -- Satisfied user of Linux since 1997. O< ascii ribbon campaign - stop html mail - www.asciiribbon.org -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/