The solution is to not change the reference, but the dereferenced hash:# This line would discard the reference to %Fruits, and create a *new* # hash with the specified values # $Ref_to_Hash = { "Pears", 5, "Peaches", 7 };
%$Ref_to_Hash = ( "Pears", 5, "Peaches", 7 );
In reply to Re^2: Modify a hash via its reference
by bart
in thread Modify a hash via its reference
by Philippe
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |