Link to home
Start Free TrialLog in
Avatar of alexiat
alexiat

asked on

Sort question

I have up to 4000 items to sort.  These items need to be sorted on 2 fields - first on a numeric field and then on a string field.  For example:

1,widget; 3,zebra; 1,apple should be sorted as 1,apple; 1,widget; 3,zebra.

I don't have a particular data structure in mind yet.  Could anyone tell me what will be the most efficient way and structure for this kind of sort.  There are a number of options available but I would like to minimize memory usage and maximize speed.  

Thanks for any guidance.
alexia
ASKER CERTIFIED SOLUTION
Avatar of monir
monir

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of alexiat
alexiat

ASKER

Thanks.  Just wasn't sure which sort and data structure would be the most efficient.