logn search for if an array has an element that matches the index, assuming the array meets certain restrictions described in the implementation file