my $a=@_[0];
Unpacking @_ with explicit subscripts is inefficient and unsightly. Using an array slice in a scalar context is also messy.
ormy ($a)=@_;
my $a=shift;
In reply to Re^2: passing arrays to subroutines
by nobull
in thread passing arrays to subroutines
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |