in reply to Replace the value of a hash
for (values %hash1) { $_ = $hash2{$_} if exists $hash2{$_}; } [download]