News for hackers. Stuff that matters.
Re:The Perl Foundation will now be known as The Perl and Rak... by eduction on Monday October 31, 2022 @01:21PM (#33409176)
Ah ok I think I remember now:

  my @foo = (1,2);
  $foo[1]; #2

  my $foo_r = \@foo
  $foo_r->[1]; #2

  my @bar = (1,2,$foo_r);
  $bar[2]->[1]; #2
Re the sigils, you're right, I would just add, $ is for scalar and a scalar iirc can be /either/ a value or a reference, that's why $foo_r and $foo[1] above both start with $. That's what I found unhelpful, it would have been nice to have a distinct sigil for refs (but presumably Larry was out of available symbols at that point!).

There are no comments on this comment yet.