0
Say you have an array that is "semi-sorted", e.g. something like this:
[7,8,9,10,1,2,3,4,5,6]
Where a part of the end of the sorted array was transferred to the beginning.
Is there a way to still find an element in it in log(n) time?
Here's my solution:
public static boolean find(int[] arr,...