Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re: Referencing Array Slices as Lists?by takshaka (Friar) |
on Sep 05, 2000 at 12:10 UTC ( [id://31098]=note: print w/replies, xml ) | Need Help?? |
You're thinking that an array slice is itself an array,
but it is actually a list. And when you take
a reference to a list you get a list of references.
Notice that a slice in scalar context acts like a list (returning the last element), not like an array (returning the number of elements):
In Section
Seekers of Perl Wisdom
|
|