Hey all, I'm trying to find a quick way to sort an array. This array has one element, a structure, and this structure has two elements. Something like this:
struct MS MyArray;
Now I want to sort the array based on arg2. Does anybody know a quick way of doing this. I've thought about doing a bubble sort, but there has to be a quicker way. I've tried using qsort, but I can't figure out how to make it look at arg2 as the sort key.
I need the code in C, not C++, and it must be ANSI compatable and able to run in DOS. I'm using MS VC 1.52c for MSDOS programs.