File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
src/algorithms/sorting/quick-sort Expand file tree Collapse file tree 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
272272| ** Selection sort** | n<sup >2</sup > | n<sup >2</sup > | n<sup >2</sup > | 1 | No | |
273273| ** Heap sort** | n  ; log(n) | n  ; log(n) | n  ; log(n) | 1 | No | |
274274| ** 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 |
276276| ** Shell sort** | n  ; log(n) | depends on gap sequence | n  ; (log(n))<sup >2</sup > | 1 | No | |
277277| ** Counting sort** | n + r | n + r | n + r | n + r | Yes | r - biggest number in array |
278278| ** 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.
2727
2828| Name | Best | Average | Worst | Memory | Stable | Comments |
2929| --------------------- | :-------------: | :-----------------: | :-----------------: | :-------: | :-------: | :-------- |
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 |
3131
3232## References
3333
You can’t perform that action at this time.
0 commit comments