Apple Interview Question

binary search