In the Union/Find algorithm, the ranks of the nodes on a path will increase monotonically from?

Category: QuestionsIn the Union/Find algorithm, the ranks of the nodes on a path will increase monotonically from?
Editor">Editor Staff asked 4 weeks ago

In the Union/Find algorithm, the ranks of the nodes on a path will increase monotonically from?
 
(a) leaf to root
 
(b) root to node
 
(c) root to leaf
 
(d) left subtree to right subtree
 
Question is taken from Trees in section Trees of Data Structures & Algorithms I
 
This question was addressed to me in my homework.

1 Answers
Editor">Editor Staff answered 4 weeks ago

Right choice is (a) leaf to root
 
To explain: One of the lemmas state that, in the Union/Find algorithm, the ranks of the nodes on a path will increase monotonically from leaf to root.