CureFit | Right most node in last level of complete binary tree
Anonymous User
5534

Problem - Given a binary tree how to find the position of right most node in last level of complete binary tree? NOTE : try to solve this in less than O(n) and use minimum possible space.
e.g - [18,15,30, 40,50,100,40,8,7,9,null,null,null,null,null]

   18
  /  \
 15   30
 / \  /  \
40 50 100 40
/ \ /
8 7 9

Ans. - 9

Can anyone provide me solution and explanation to this problem?

Comments (12)