Binary Search Questions Leetcode Contest Solution