in reply to Re: using function delete with arrays
in thread using function delete with arrays

Your understanding is incorrect. scalar(@array) returns the number of elements in an array. Whether the element is defined or not doesn't matter:
$ perl -e '@arr = (1, 2, 3); print scalar(@arr), "\n"' 3 $ perl -e '@arr = (undef, undef, undef); print scalar(@arr), "\n"' 3