Sorting anything with qsort

Jerry Ludwig jludwig at pro-grouch.cts.com
Sun Mar 24 22:36:06 AEST 1991


   Recently, (friday, that is) I finished my first program that sort using
qsort.  The problem with sorting ANYTHING with qsort is that it wants an
array.  I had to sort records in a file.  Another problem is that qsort
takes only an unsigned int as the number of arguements and the files I had
to sort could easily be multiple megs (a record was only 14 bytes).     Now
all of this was solved easily using multiple qsorts on records read into
a huge array and then merging the qsorts into the final file. But qsort is
not an end all for sorting ANYTHING by any stretch of the imagination. 
qsort is a big help on almost all fixed size elements.
                        Your friendly Windows developer,
                            Jerry.
----
ProLine:  jludwig at pro-grouch
Internet: jludwig at pro-grouch.cts.com
UUCP:     crash!pro-grouch!jludwig
ARPA:     crash!pro-grouch!jludwig at nosc.mil



More information about the Comp.lang.c mailing list