in reply to Sorting Arrays Without using SORT function

Why do you not want to use sort? If you don't want to sort lexicographically, you can specify your own comparator: see How do I sort an array by (anything)? in perlfaq4.
  • Comment on Re: Sorting Arrays Without using SORT function