Hi Im fairly new to perl and I am pretty stumped on a problem that I am having with hashes and trying to access a value of a key when I assign the value to be an array filled with stuff. I try to print the key and the value it returns is some crazy random numbers an integers like 3hx0jeh5. Please help
print "Enter the value";
my $item_to_push = <STDIN>;
my @array = ('derp');
push(@array, $item_to_push);
print @array;
my %names;
$names{'bill'} = [@array];
print $names{'bill'};
As you see I create a hash called %names, I assign a key in it called 'bill' to @array ( so that it is its value ), and I then try to print the value of the key 'bill' but this is what comes up.
ARRAY(0x81c1f0)