I have a dynamic array created as follows:
window.IDarray = [];
And I have a dictionary created like this:
window.itemdictionary = {};
The window.IDarray same as the window.itemdictionary . And the window.IDarray values window.IDarray unique. Also, window.IDarray values are keys to window.itemdictionary .
The data type of the "value" of any key in window.itemdictionary also a dictionary that contains a key called "modified" , and the value is the string date of the example format "Mon May 28 11:20:46 EDT 2012" .
What is the best way to sort window.IDarray values, so that going from index 0 to the end of window.IDarray , its corresponding dates in window.itemdictionary get farther from the current date? (i.e., index 0 will give the closest date to the current date, and index n will give the most remote date).
omega source share