TIP: Click on subject to list as thread! ANSI
echo: c_echo
to: Jasen Betts
from: Charles Angelich
date: 2003-08-15 23:27:34
subject: getopt()

1237c99eff4e
c_echo



Hello Jasen - 

--8<--cut 

CA>>>> There are so many clones of "copy" I never thought to
CA>>>> write another one but I have written a dropin
CA>>>> replacement for "sort" in all C code. 

JB>>> same.... limited to available meory but atleast it uses
JB>>> an Order(n.log(n)) sort algorithm (qsort() actually)
JB>>> (which is a vast improvemnt on the n-squared algorithm in
JB>>> the dos one. 

CA>> Not clear on what "same" you refer to here. 

JB> I did the same thiung. 

Ah ... OK, gotcha'. 

CA>> The definitive DOS sort was already written, RPSORT, in
CA>> ASM and can use virtual memory (hard drive) if necessary. 

JB> I didn't know that.... thanks. 

If you can't locate it there is a link to RPSORT on the DOS
utilities page of my tech website.

CA>> I guess that describes it but as I said, I used the K&R
CA>> qsort and I _think_ I wrote my own function to compare the
CA>> strings? 

CA>> It's been some years ago now and I haven't even looked at
CA>> my sort code for many of those years. I did write a
CA>> similarity sort some years back but that is a horse of a
CA>> different color. 

JB> I remember that thread.... I didn't participate as trying
JB> to compreess N dimensions into 1 seemed like an impossible
JB> task to me... I still have your and Bills source I think... 

Bills source. I never posted any of mine. 

CA>> We've had many interesting discussions of sorting
CA>> algorithms here in the c_echo not long ago and Bill
CA>> Buckels did a really good job writing his similarity sort
CA>> routines with a little prodding from me. Of the three
CA>> sim-sorts I know of mine is still the fastest but Bill's
CA>> is the most capable for larger files. :-) 

JB> my only contribution to sorting algorithms was a way to
JB> apply a radix sort (which is order N and thefore faster
JB> than qsort etc on lkarge lists) to floating point data...
JB> dunno if anyone reembers that. 

Yes, I remember RADIX but there were so many who were posting
their favorites and variations I don't recall who posted what.
Didn't you also include code to time-test various sorts for
comparison to RADIX? 

>
>        ,                          ,
>      o/      Charles.Angelich      \o       ,
>       __o/
>     / >          USA, MI           < \   __\__
 

___ * ATP/16bit 2.31 * 
... DOS the Ghost in the Machine! http://www.undercoverdesign.com/dosghost/

--- Maximus/2 3.01
* Origin: COMM Port OS/2 juge.com 204.89.247.1 (281) 980-9671 (1:106/2000)
SEEN-BY: 633/267 270
@PATH: 106/2000 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.