File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -90,11 +90,12 @@ Below is the list of some of the most used Big O notations and their performance
90
90
![ Common Data Structure Operations] ( https://github.com/trekhleb/javascript-algorithms/blob/master/assets/big-o-data-structures.png )
91
91
Source: [ Big O Cheat Sheet] ( http://bigocheatsheet.com/ ) .
92
92
93
- ### Array Sorting Algorithms
93
+ ### Array Sorting Algorithms Complexity
94
94
95
95
![ Big O of sorting algoritms] ( https://github.com/trekhleb/javascript-algorithms/blob/master/assets/big-o-sorting-algorithms.png )
96
96
Source: [ Big O Cheat Sheet] ( http://bigocheatsheet.com/ ) .
97
97
98
- | Name | Best | Average | Worst | Memory | Stable | Method | Notes |
99
- | ------------------| :-----: | :-------: | :-----: | :-------: | :-------: | :------------ | :-------------- |
100
- | ** Bubble sort** | n | n^2 | n^2 | 1 | Yes | Exchanging | Tiny code size. |
98
+ | Name | Best | Average | Worst | Memory | Stable | Method | Notes |
99
+ | --------------------- | :-----: | :-------: | :-----: | :-------: | :-------: | :------------ | :-------------- |
100
+ | ** Bubble sort** | n | n^2 | n^2 | 1 | Yes | Exchanging | Tiny code size |
101
+ | ** Selection sort** | n^2 | n^2 | n^2 | 1 | No | Selection | Stable with O(n) extra space, for example using lists |
You can’t perform that action at this time.
0 commit comments