Help


from Wikipedia
« »  
These constraints enforce a critical property of red – black trees: that the path from the root to the furthest leaf is no more than twice as long as the path from the root to the nearest leaf.
The result is that the tree is roughly height-balanced.
Since operations such as inserting, deleting, and finding values require worst-case time proportional to the height of the tree, this theoretical upper bound on the height allows red – black trees to be efficient in the worst case, unlike ordinary binary search trees.
Red-black trees are in general not weight-balanced, that is sibling nodes can have hugely differing numbers of descendants.

2.049 seconds.