Lecture 17 Red-Black Trees
Lecture 17 Red-Black Trees
21
22
22
1
12-May-23
23
23
24
24
2
12-May-23
25
25
26
26
3
12-May-23
27
27
28
28
4
12-May-23
29
Scenario 1: Z = Root
Solution:
Color Z Black
30
30
5
12-May-23
31
31
32
32
6
12-May-23
33
33
34
7
12-May-23
References:
1. https://www.guru99.com/avl-tree.html
2. https://en.wikipedia.org/wiki/AVL_tree
3. https://en.wikipedia.org/wiki/Red-black_tree
4. https://www.geeksforgeeks.org/avl-tree-set-1-insertion/?ref=lbp
5. https://www.youtube.com/watch?v=qvZGUFHWChY
6. https://www.geeksforgeeks.org/red-black-tree-set-1-introduction-2/
35
35