Black red tree - creating a node with at most one child

76 Views Asked by At

Let's assume I have a black red tree with integers values, for which I know the values of the nodes, but not the topology of the tree.

I can insert new numbers into the tree, but cannot insert numbers that are bigger than the tree's maximum node or smaller than the tree's minimum node.

When i insert a number, a new node with this number is inserted and than the tree stabilises itself.

What series of numbers could I insert, that will create a situation where one of my inserted numbers has one or zero children?