in reply to check element if inside an array
my %hash = map { $_ => 1 } 'a' .. 'f'; $hash{b} = 'added' unless exists $hash{b}; $hash{g} = 1 unless exists $hash{g}; print %hash; __output__ e1f1g1a1b1c1d1 [download]
_________broquaint