Amazon Interview Question

Binary search tree and Binary Heap