2 ms·
For a simple sort you can use for small N, I'd suggest insertion sort. Its constants are better, it performs well on almost-sorted input, and I think it's even
by kadoban 7y ago
For a simple sort you can use for small N, I'd suggest insertion sort. Its constants are better, it performs well on almost-sorted input, and I think it's even easier to implement, personally.
- mark-r 7y agoYes, I've heard that suggestion many times since then. I wasn't well versed on the different sorts at the time.