A hash can't have a key without a value (that's why I refer to key/value pairs). If you reference $h{x} in some fashion (except as a target for exists) then a x/undef pair is created (autovivified) for %h if it didn't exist already. The undef returned by $h{x} is the value associated with the key 'x'.
"Adding" an undef value to %h when $h{x} is used is exactly what autovivification does.
In reply to Re^5: Keys() required to autovivify?
by GrandFather
in thread Keys() required to autovivify?
by jrw
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |