Article View: comp.lang.modula2
Article #246Re: Sorts
From: Alex Bewley
Date: Tue, 12 Sep 1989 00:20
Date: Tue, 12 Sep 1989 00:20
15 lines
1326 bytes
1326 bytes
Bubble sort is a little bit too slow for my application. I need to sort
a linked list in memory. The algorithm I want must not use or
require a FIXED array to sort, as the list is dynamic.
Lists are not like arrays either, if you go swapping elements in the list
pointers become mixed up and you end up trying to sort the interrupt table
or screen (which isnt't very good).
For the time being I have to use a fixed ARRAY OF POINTERS and then sort
the array using a comparison routine that checks the information
that the pointers are pointing to, which suprisingly works, but strikes me
as being a rather ridiculous way to sort the list. Besides, the array
limits the amount of information I can store, which I don't want to do.
Alex
Just this guy...
Technical Details
Message-ID:
<INFO-M2%89091120313809@UCF1VM>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!uakari.primate.wisc.edu!aplcen!ginosko!brutus.cs.uiuc.edu!usc!ucsd!ucbvax!UOGUELPH.BITNET!BOTCHAIRReferences:
<heilpern@VAX1.ACS.UDEL.EDU>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uwm.edu!uakari.primate.wisc.edu!aplcen!ginosko!brutus.cs.uiuc.edu!usc!ucsd!ucbvax!UOGUELPH.BITNET!BOTCHAIR From: BOTCHAIR@UOGUELPH.BITNET (Alex Bewley) Newsgroups: comp.lang.modula2 Subject: Re: Sorts Message-ID: <INFO-M2%89091120313809@UCF1VM> Date: 12 Sep 89 00:20:08 GMT References: <heilpern@VAX1.ACS.UDEL.EDU> Sender: daemon@ucbvax.BERKELEY.EDU Reply-To: Modula2 List <INFO-M2%UCF1VM.bitnet@jade.berkeley.edu> Organization: The Internet Lines: 15