in reply to exists puzzle
You by mistake used curly brackets instead of parens, so your %testhash does not have 'key1' or 'key2' keys at all. It is ({some hash ref} => undef).
update:
use strict; use Data::Dumper; my %testhash = { 'key1' => 'val1' , 'key2' => 'val2' }; print Dumper(\%testhash); ### $VAR1 = { 'HASH(0x2251b0)' => undef };
|
|---|