Red-Black Trees

What is a Red-Black Tree?

A Red-Black Tree is a type of self-balancing binary search tree that uses a color property for each node to ensure operation efficiency.

Key Properties

Why Use Red-Black Trees?

  1. O(log n) time complexity
  2. Automatically balanced
  3. Can be used to implement Dijkstra's shortest path algorith and Prim's minimum spanning tree alogorithm

Example

Learn More

Click here to learn more about Red-Black Trees