$array[$x]->{"foo"}->[0] = "January"; This is one of the cases we mentioned earlier in which references could spring into existence when in an lvalue context. Before this statement, $array[$x]may have been undefined. If so, it's automatically defined with a hash reference so that we can look up {"foo"}in it. Likewise $array[$x]->{"foo"}will automatically get defined with an array reference so that we can look up [0]in it. One more thing here.