3 ms·
Good point but it's not exactly a free lunch. You're trading memory for the speedup. You can also use radix sort for what I'd like to call "fake" O(n) sort sin
by trinovantes 4y ago
Good point but it's not exactly a free lunch. You're trading memory for the speedup.
You can also use radix sort for what I'd like to call "fake" O(n) sort since physical hardware puts an upper limit on the hidden constant.
- saagarjha 4y agoRadix sort generally places far more restrictions on the keys than a set would.