Data Structures Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

What conditions must a red-black tree satisfy?

A

1) Nodes are either red or black
2) The root is black (optional)
3) All leaves (NIL) are black, i.e. the same color as the root
4) Every red node must have two black child nodes, and therefore must have a black parent
5) Every path from a given node to any of its descendant NIL nodes contains the same number of black nodes.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly