Quick Sort Algorithm
Quick Sort Algorithm
Disadvantages of Quicksort:
Divide:
Conquer:
1. Time Complexity:
- Optimal Case: Quicksort performs best when the pivot
element is centrally positioned or close to the center, exhibiting
a time complexity of O(n*logn).
2. Space Complexity:
23 8 28 13 12 18 26
23 8 28 13 12 18 26
23 8 13 12 18 26 28
Continue recursively.
23 8 13 12 18
8 13 12 18 24
8 12 13 18 24
Finish.
8 12 13 18 24 26 28
Quick Sorting program in Python.