https://www.reddit.com/r/java/comments/di7plt/local_methods_coming_to_java/
public static int binarySearch(int[] a, int key) {
return binarySearch0(a, 0, a.length, key);
int binarySearch0(int[] a, int start, int stop, int key) {
....do the actual search
calls binarySearch0(.....) recursively
}
}