Returns the index of the first appearance of the value target in array. @param array an array of int values, possibly empty @param target a primitive int value @return the least index i for which array[i] == target, or -1 if no such index
(int[] array, int target)
| 166 | |
| 167 | |
| 168 | public static int indexOf(int[] array, int target) { |
| 169 | return indexOf(array, target, 0, array.length); |
| 170 | } |
| 171 | |
| 172 | // TODO(kevinb): consider making this public |
| 173 |
no test coverage detected