Welcome to the Monastery | |
PerlMonks |
Re: Passing Any Range of Values to a Subby David Caughell (Monk) |
on Jul 02, 2003 at 05:43 UTC ( [id://270711]=note: print w/replies, xml ) | Need Help?? |
Hi there. I'm also a student learning the language. Personally, I think it's best to always use: my $size = scalar(@testarr); rather than: my $size = @testarr; Because it's easier to understand and by naming something you exert a little more control over it. It also helps stress the difference between scalars and arrays, which is helpful for me as a student. I'd be interested in knowing what the more established users of the language think about using scalar() rather than using only the array. Any comments? David Caughell.
In Section
Seekers of Perl Wisdom
|
|