File tree 2 files changed +2
-2
lines changed
src/algorithms/sorting/quick-sort
2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -272,7 +272,7 @@ Below is the list of some of the most used Big O notations and their performance
272
272
| ** Selection sort** | n<sup >2</sup > | n<sup >2</sup > | n<sup >2</sup > | 1 | No | |
273
273
| ** Heap sort** | n  ; log(n) | n  ; log(n) | n  ; log(n) | 1 | No | |
274
274
| ** Merge sort** | n  ; log(n) | n  ; log(n) | n  ; log(n) | n | Yes | |
275
- | ** Quick sort** | n  ; log(n) | n  ; log(n) | n<sup >2</sup > | log(n) | No | |
275
+ | ** Quick sort** | n  ; log(n) | n  ; log(n) | n<sup >2</sup > | log(n) | No | Quicksort is usually done in-place with O(log(n)) stack space |
276
276
| ** Shell sort** | n  ; log(n) | depends on gap sequence | n  ; (log(n))<sup >2</sup > | 1 | No | |
277
277
| ** Counting sort** | n + r | n + r | n + r | n + r | Yes | r - biggest number in array |
278
278
| ** Radix sort** | n * k | n * k | n * k | n + k | Yes | k - length of longest key |
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ The horizontal lines are pivot values.
27
27
28
28
| Name | Best | Average | Worst | Memory | Stable | Comments |
29
29
| --------------------- | :-------------: | :-----------------: | :-----------------: | :-------: | :-------: | :-------- |
30
- | ** Quick sort** | n  ; log(n) | n  ; log(n) | n<sup >2</sup > | log(n) | No | |
30
+ | ** Quick sort** | n  ; log(n) | n  ; log(n) | n<sup >2</sup > | log(n) | No | Quicksort is usually done in-place with O(log(n)) stack space |
31
31
32
32
## References
33
33
You can’t perform that action at this time.
0 commit comments