From fbf12c3259987eebd73b6014a2073c89ac5a064d Mon Sep 17 00:00:00 2001 From: GohJunLe <108907711+GohJunLe@users.noreply.github.com> Date: Sat, 3 Sep 2022 17:21:32 +0800 Subject: [PATCH] Update src/algorithms/search/exponential-search/exponentialSearch.js Co-authored-by: codacy-production[bot] <61871480+codacy-production[bot]@users.noreply.github.com> --- src/algorithms/search/exponential-search/exponentialSearch.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/algorithms/search/exponential-search/exponentialSearch.js b/src/algorithms/search/exponential-search/exponentialSearch.js index af78b2c2..7a0ff056 100644 --- a/src/algorithms/search/exponential-search/exponentialSearch.js +++ b/src/algorithms/search/exponential-search/exponentialSearch.js @@ -50,6 +50,6 @@ export default function exponentialSearch(sortedArray, seekElement, comparatorCa while (range < length && comparator.lessThanOrEqual(sortedArray[range], seekElement)) { range *= 2; } - // Call binary search for the found range. + // Call binary search for the found range. return binarySearch(sortedArray, range/2, Math.min(range, length - 1), seekElement, comparatorCallback); } \ No newline at end of file