I find your example rather misleading as your variable
$HASH is not referring to a hash structure at all but to an array. You are using
push, which pushes an element onto the right-hand, or top, end of an array and you are using the
@ sigil to dereference
$HASH to get at the array it refers to. You say "dump the whole hash" when using
Data::Dumper but again you are supplying a reference to an array and, by enclosing the argument in anonymous hash constructors
Data::Dumper->Dump([$HASH]), you are actually going to see an array of arrays in your output. Something like
$VAR1 = [
[
'data1',
'data2',
'data3'
]
];
Later you loop over the array printing out each element but you confuse things again by referring to each as a key. Arrays don't have keys, hashes do. Also, why do you declare the scalar $value then never use it?
Cheers,
JohnGG