in reply to Re^4: Having an Issue updating hash of hashes
in thread Having an Issue updating hash of hashes
They are not needed on the left side of "fat commas" (=>) because the fat comma automatically stringifies its left argument, and also not needed on the right side of the fat commas here because the values are already stored into variables. And, BTW, with respect to boftx's suggested explanation, preserving leading zeros doesn't seem to be a sufficient reason, as it appears that any leading zero(s) in these variable will be preserved and that Perl will not "numify" the hash values, as shown in this example under the Perl debugger:push @people, { id => $id, first => $first, last => $last, age => $age, };
DB<13> $s = "003"; DB<14> %h = (string => $s); DB<15> x %h 0 'string' 1 003
|
|---|