FinBox interview question

DSA on BS and trees