Red-Black Tree. Insert values and watch the tree self-balance via recoloring and rotations to maintain the red-black invariants.

Red-Black Tree · self-balancing BST red node black node fixup focus new node
Ready

A valid red-black tree is loaded. Type a value and press Insert or Search — or run a demo below to watch recoloring and rotations fix red-red violations.

Speed
Demos
nodes
0
height
0
recolors
0
rotations
0