Medium · O(n log n) avg, O(n²) worst
Quick Sort quiz
Pick an answer to see whether it's right, and why. Nothing is saved or sent.
Question 1 of 10
- Question 1: current
- Question 2: not answered yet
- Question 3: not answered yet
- Question 4: not answered yet
- Question 5: not answered yet
- Question 6: not answered yet
- Question 7: not answered yet
- Question 8: not answered yet
- Question 9: not answered yet
- Question 10: not answered yet
This quick sort picks its pivot as the median of three. Which value is the pivot for [7, 2, 9, 4, 3, 8, 1]?
Take it further
- AnimationSorting
Quick Sort Animation
Quick sort, step by step: the pivot, Hoare's two pointers and a call stack that stays shallow
Free
