in reply to Re^2: Dereferencing a Hash of Arrays
in thread Dereferencing a Hash of Arrays

@idontgetit holds the two array refs. @idontgetit->[0] indexes the first one of it, and the second ->[0] indexes the first element of the (inner) array.

BTW, @idontgetit->[0]->[0] should better be written as $idontgetit[0]->[0]   (turn on warnings, and Perl will tell you why).

Replies are listed 'Best First'.
Re^4: Dereferencing a Hash of Arrays
by toro (Beadle) on Jun 14, 2011 at 07:39 UTC
    I saw that warning before (I try to crack these nuts for a few hours before I ask the monks). I failed with $idontgetit->[0]->[0] and just went back to the @ syntax since it printed anything. Sometimes Perl forgives my syntax, sometimes not.