McDonald's interview question

Asked me to code a solution involving binary search