Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » U++ Developers corner » Funny way how NOT to speedup sorting of small arrays
Re: Funny way how NOT to speedup sorting of small arrays [message #19916 is a reply to message #19909] Sun, 01 February 2009 20:13 Go to previous messageGo to previous message
mr_ped is currently offline  mr_ped
Messages: 826
Registered: November 2005
Location: Czech Republic - Praha
Experienced Contributor
I think with 10+ elements already quicksort can pay off. A well implemented quicksort will not hurt even with 2-3 elements that much.

Then the question is also, what do you sort, and how much the data can be pre-sorted already, in such case you can either avoid sort at all, or bubble sort can yield best results if every element is already close to it's sorted order position.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: 1538 compilation fails
Next Topic: German language added to Docking.t of bazar/Docking
Goto Forum:
  


Current Time: Tue Aug 26 19:13:34 CEST 2025

Total time taken to generate the page: 0.06074 seconds