public int oneSidedBinarySearch(int[] arr, int K) {

		int log2 = getLog(arr.length);
		int currentI = 0;

		while (log2 >= -1) {

			System.out.println("currentI: " + currentI);
			System.out.println("arr[currentI]: " + arr[currentI]);

			if (arr[currentI] == K) {
				return arr[currentI];

			} else if (arr[currentI] < K) { // jump right

				int newIndex = currentI + (1 << log2);

				if (newIndex < arr.length) {
					currentI = newIndex;
				}
			} else { // jump left

				currentI = currentI - (1 << log2);
			}

			log2--;

		}
		return -1;
	}