in reply to A hash of lists
A suggestion: use Data::Dumper to save you the trouble of all those typing. :)my @test = qw / bing bong bang /; print '['.$test[2].'] ['.$test[1].'] ['.$test[0]."]\n"; $bits{'one'}= \@test; # hash entry from a reference to array my @new = @{$bits{'one'}}; # get back the array from the hash print '['.$new[2].'] ['.$new[1].'] ['.$new[0]."]\n";
use Data::Dumper; @test = qw / bing bong bang /; print Dumper(\@test); $bits{'one'}= \@test; @new = @{$bits{'one'}}; print Dumper(\@new);
|
|---|