Skip to content

Commit dfdd1ac

Browse files
committedApr 15, 2018
Add quick sort.
1 parent 278ca89 commit dfdd1ac

File tree

2 files changed

+22
-3
lines changed

2 files changed

+22
-3
lines changed
 

‎README.md

+22-3
Original file line numberDiff line numberDiff line change
@@ -89,10 +89,29 @@ Below is the list of some of the most used Big O notations and their performance
8989
| **O(2^N)** | 1024 | 1.26e+29 | 1.07e+301 |
9090
| **O(N!)** | 3628800 | 9.3e+157 | 4.02e+2567 |
9191

92-
### Common Data Structure Operations
92+
### Common Data Structure Operations Complexity
9393

94-
![Common Data Structure Operations](https://github.com/trekhleb/javascript-algorithms/blob/master/assets/big-o-data-structures.png)
95-
Source: [Big O Cheat Sheet](http://bigocheatsheet.com/).
94+
<table>
95+
<tr>
96+
<td>One</td>
97+
<td>Two</td>
98+
</tr>
99+
<tr>
100+
<td colspan="2">Three</td>
101+
</tr>
102+
</table>
103+
104+
| Data Structure | Access | Search | Insertion | Deletion |
105+
| ----------------------- | :-------: | :-------: | :-------: | :-------: |
106+
| **Array** | 1 | n | n | n |
107+
| **Stack** | n | n | 1 | 1 |
108+
| **Queue** | n | n | 1 | 1 |
109+
| **Linked List** | n | n | 1 | 1 |
110+
| **Hash Table** | | n | n | n |
111+
| **Binary Search Tree** | n | n | n | n |
112+
| **B-Tree** | log(n) | log(n) | log(n) | log(n) |
113+
| **Red-Black Tree** | log(n) | log(n) | log(n) | log(n) |
114+
| **AVL Tree** | log(n) | log(n) | log(n) | log(n) |
96115

97116
### Array Sorting Algorithms Complexity
98117

‎assets/big-o-data-structures.png

-351 KB
Binary file not shown.

0 commit comments

Comments
 (0)
Please sign in to comment.