BearCola
7/25/2017 - 3:58 AM

search.java (2-3 08:42)

search.java (2-3 08:42)

int search(int[] data, int begin, int end, int target) {
  if (begin > end) {
    return -1;
  } else if (target == items[begin]) {
    return begin;
  } else {
    return search(data, begin + 1, end, target);
  }
}