Amazon Interview Question

questions were on array and trees