Question 114Asked in BPSC TRE 2.0 (2023) Computer Class 9-10Which of the following satisfies the property of the red-black tree?
- ABlack, if the new node is a root node
- BRed, if the new node is not a root node
- CBlack, if the new node is not a root node
- DMore than one of the above
- ENone of the above
Show answerHide answer
Correct answer: (D) More than one of the above
Explanation
In a red-black tree the root is black and a newly inserted non-root node is coloured red, so both A and B hold (more than one).