Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question: ⭐ (sorting)
I have an array of arrays which I need to sort according to the value of the second element of the anonymous arrays that are being referenced by the named array. (did that make sense?)
How do I do this exactly?
@array = [8,9,10], [4,5,6], [7,8,9]; # This is the array of arrays I need to sort # by second elements. # Magic step goes here.... # I need to end up with an array like @sorted: @sorted = [4,5,6], [7,8,9], [8,9,10];
Originally posted as a Categorized Question.
Back to
Seekers of Perl Wisdom