getting closer to binary search