parent
69d0070c99
commit
d22420fea8
@ -31,7 +31,7 @@ class BinarySearch implements SearchAlgorithm {
|
||||
*/
|
||||
@Override
|
||||
public <T extends Comparable<T>> int find(T[] array, T key) {
|
||||
return search(array, key, 0, array.length);
|
||||
return search(array, key, 0, array.length - 1);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user