length is for getting string lengths. To get the number of elements, simply use the array in scalar context:
my $elems = @$array_ref;
In reply to Re: How to find number of elements of an array from array reference
by moritz
in thread How to find number of elements of an array from array reference
by chakreey
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |