Tag: timsort
-
Sorting Algorithm Speed: 100 to 10K Elements Benchmark
At 1000 elements, Python's sorted() beats hand-written quicksort by 47x. Real benchmark data for interview-size arrays with the numbers behind why.
-
Bubble Sort to Timsort: Why Python Ditched O(nยฒ)
Python's sorted() uses Timsort, not the bubble sort from textbooks. Here's the 85x speed gap, stability trade-offs, and when O(nยฒ) beats O(n log n).
-
Python Sorting Benchmarks: Which Algorithm Wins?
Compare Python sorting algorithms with real benchmarks. The winner might surprise you โ discover which method dominates speed tests across different data sizes.