BrowserStack Interview Question

Lowest Common Ancestor

Interview Answer

Anonymous

Jan 18, 2021

If it is in the case of BST. Suppose val-1 and val_2 are the values to be searched. Pseudo code While (root! -null) If (val-1 > root-value and val-2