October 2025
Intermediate to advanced
485 pages
13h 2m
English
The following exercises provide you with the opportunity to practice with red-black trees. The solutions to these exercises are found in the section Chapter 5.
Here’s a simple tree:

It’s not supposed to be a red-black tree, don’t worry. However, we can still perform a rotation on it. Show what the tree will look like after you rotate the A and the B.
Here’s a red-black tree:

Rotate the 80 and the 100. Don’t worry about violating the Red-Black Rules and having to fix up the tree after the rotation. Simply show what would happen if that ...
Read now
Unlock full access