function binarySelect(arr, evaluator, opt_obj) {
  return binarySearch_(
      arr, evaluator, true /* isEvaluator */, undefined /* opt_target */,
      opt_obj);
}
Selects an index in the specified array using the binary search algorithm.
The evaluator receives an element and determines whether the desired index
is before, at, or after it.  The evaluator must be consistent (formally,
map(map(arr, evaluator, opt_obj), goog.math.sign)
must be monotonically non-increasing).

Runtime: O(log n)

@param {IArrayLike<VALUE>} arr The array to be searched.
@param {function(this:THIS, VALUE, number, ?): number} evaluator
    Evaluator function that receives 3 arguments (the element, the index and
    the array). Should return a negative number, zero, or a positive number
    depending on whether the desired index is before, at, or after the
    element passed to it.
@param {THIS=} opt_obj The object to be used as the value of 'this'
    within evaluator.
@return {number} Index of the leftmost element matched by the evaluator, if
    such exists; otherwise (-(insertion point) - 1). The insertion point is
    the index of the first element for which the evaluator returns negative,
    or arr.length if no such element exists. The return value is non-negative
    iff a match is found.
@template THIS, VALUE