Red-Black Trees
A Red-Black Tree is a self-balancing binary search tree where each node
is either red or black with certain properties.
Core Properties
- Every node is either red or black.
- The root and all leaves (NIL) are always black.
- If a rode is red, then both its child are black.
- Every path from a node to its descendant leaves contains the same number of black nodes.
Structure Diagram
You can learn more about the insertion and deletion rules by clicking here:
Click Here