I have a binary tree which is not balanced. The height of the tree is unknown because the tree is changing during the algorithm. I want to pick a node randomly from the tree, or from any subtree of this tree. How can I do this efficiently?
Thank you in advance..