Sorting algorithms

Alright so I've been doin some research on sorting algorithms and would like some opinions from real people. What is, in your opinion, the best sorting algorithm out there. I would like to know your favorite for large and small arrays (so list at least 2 algorithms). Also say why you like it. Thanks!
I'm sorry to disappoint you, but most people don't have strong views about their sorting algorithm preferences. Most of the time it doesn't really matter as long as it has good complexity. In special cases, any information you may need to choose which one to use should be available in wikipedia. In all others, you can trust std::sort to perform well.
closed account (z05DSL3A)
Bogosort and Bubble sort.






Yes, I am pulling your leg.
+1 hamsterman

I use insertion sort for small arrays, and quicksort for large ones :)
std::sort? How does this work?
I believe the algorithm of std::sort() is actually implementation defined.
http://cplusplus.com/reference/algorithm/sort/
Bogosort


Quantum Bogosort is where it's at!
Topic archived. No new replies allowed.