gitarwmn has asked for the wisdom of the Perl Monks concerning the following question:
Say you have an array with numbers and strings...
@array = qw(1 fred);
and you want to sort it by the second element in the array which is a string, how can this be done?
Thanks
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: sort an array by an specific element
by atcroft (Abbot) on Feb 06, 2005 at 00:01 UTC | |
|
Re: sort an array by an specific element
by punkish (Priest) on Feb 06, 2005 at 01:39 UTC | |
|
Re: sort an array by an specific element
by Fletch (Bishop) on Feb 05, 2005 at 23:54 UTC |