in reply to How to declare a hash of array?

You don't have to initialize hash members. Doing the following will work as long as $hash, $key, and $insert_value are initialized themselves:
#!/user/bin/env perl use strict; use warnings; use Data::Dumper; my %hash = (); my $key = 'A'; my $insert_value = 123; push(@{$hash{$key}},$insert_value); print Dumper(\%hash);
Output:
$VAR1 = { 'A' => [ 123 ] };