in reply to Re: Learning to *really* love references
in thread Learning to *really* love references
but when I tried to debug or simply read it a few months after coding, it took me a long time to make my brain think the same, wired way as when I wrote the code ;-)my $arrayElement = $$arrayRef[0]; my $hashValue = $$hashRef{someKey};
ormy $arrayElement = ${$arrayRef}[0]; my $hashValue = %{$hashRef}{key};
and it depends of the mood ;-)my $arrayElement = $arrayRef->[0]; my $hashValue = $hashRef->{key};
|
---|