in reply to Dereferencing a Hash of Arrays
Your problem is that the values in hashes can only be scalars in Perl. However references are scalars, so you can use references to arrays:
my %alphabet = ( a => \@atags, b => \@btags, ); say for values %alphabet;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Dereferencing a Hash of Arrays
by toro (Beadle) on Jun 14, 2011 at 07:27 UTC |
In Section
Seekers of Perl Wisdom