Syntactic Confectionery Delight | |
PerlMonks |
Re: splitting array valuesby bobn (Chaplain) |
on May 20, 2004 at 01:22 UTC ( [id://354812]=note: print w/replies, xml ) | Need Help?? |
First it sounds like you don't really know what is in $score[0] (note not @score[0], though that may work). To get around this, This will tell you what is actually in @score, where the first element will be $score[0]. Also, an array doesn't really contain another array. arrays can only contain scalars, though one type of scalar is a refrence, which can be thought of as a pointer to another array. If $score[0] is such a reference to an array, the correct notation is: This properly de-references the referance to feed an array into the sort.
--Bob Niederman, http://bob-n.com All code given here is UNTESTED unless otherwise stated.
In Section
Seekers of Perl Wisdom
|
|