by M. J. Highlander (20 Submissions)
Category: Miscellaneous
Compatability: VB Script
Difficulty: Intermediate
Date Added: Wed 3rd February 2021
Rating: (3 Votes)
Sort Array without Swapping Strings
The latest Sort submission by Ulli, whcih is unquestionably superior and advanced is, well, advanced! so i cooked-up this sort which is very simple, the algorithm used is shell sort but instead of swapping strings, we swap their index, and finally return an array of sorted indexes, well sort of (pun intended ;-)
Inputs
String Array to be Sorted
with the option of Ignoring Case
Assumes
assumes u have VB6 !!!
Code Returns
Array (of type Long) of Sorted Indexes (indices) that can be used to access the original unchanged array according to the sorted order.
Side Effects
who knows :-p