Question DSA-BST-165
HardAn AVL tree receives the keys 10, then 30, then 20. Which rebalancing is needed after the last insertion, and what becomes the root?
- A.
A single left rotation; the root becomes 30
- B.
A single right rotation; the root stays 10
- C.
Sign up free to see the answer and a step-by-step explanation.