     elif target < data[mid]:
        # recur on the portion left of the middle
        return binarySearch(data, target, low, mid - 1)
     else:
        # recur on the portion right of the middle
        return binarySearch(data, target, mid + 1, high)