RSS Forums RSS
Please support our C advertiser: Programming Forums

Quicksorting linked list - simple algorithm

Join Date: Apr 2007
Posts: 5
Reputation: iMalc is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 1
iMalc iMalc is offline Offline
Newbie Poster

Solution Re: Quicksorting linked list - simple algorithm

  #2  
May 21st, 2007
Originally Posted by openuser View Post
I came across a simple way of quicksorting linked list which is same as iterative version of quicksort for arrays...
http://www.openasthra.com/c-tidbits/...ple-algorithm/
worth a look...

Let me know if you have any other simple algorithm for QuickSort (for sorting linked lists), should be easy to understand...

Thanks.
I had a look at that link and I'm afraid to tell you that it is of very poor quality. The spelling is horrible, and in fact it does NOT really implement list-based-quicksort.

What it actually does is implement array-based-quicksort, and treats a linked-list as an array. This leads to extremely poor performance. In fact I think that the implementation on that site is about O(n^3) or N-cubed. Not to mention it is far longer than it should be for this algorithm.

Perhaps you would consider taking a look at a page from my own personal site which I am currently putting together, instead: <URL snipped>

My explanations are currently a bit too brief, I'm constantly working on it and uploading a new copy every few days. Feel free to ask me questions about it.

Also, if you don't necessarily have to use quicksort, then you may consider looking around at some of the alternatives on that page. Again, please feel free to ask for me to provide more explanations where they would help.
Last edited by Ancient Dragon : May 21st, 2007 at 8:00 am. Reason: snipped URL
Reply With Quote  
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 10:23 am.
Newsletter Archive - Sitemap - Privacy Statement - Acceptable Use Policy - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC