diff --git a/src/com/jwetherell/algorithms/search/LowerBound.java b/src/com/jwetherell/algorithms/search/LowerBound.java index 569e4532..9e6cd353 100644 --- a/src/com/jwetherell/algorithms/search/LowerBound.java +++ b/src/com/jwetherell/algorithms/search/LowerBound.java @@ -23,6 +23,7 @@ public static int lowerBound(int[] array, int length, int value) { int high = length; while (low < high) { final int mid = (low + high) / 2; + //checks if the value is less than middle element of the array if (value <= array[mid]) { high = mid; } else {