From 38d181972b57b66003a7fe3b5bd1867ab33988c4 Mon Sep 17 00:00:00 2001 From: GohJunLe <108907711+GohJunLe@users.noreply.github.com> Date: Sat, 3 Sep 2022 17:31:05 +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 d6588156..7d6b3c56 100644 --- a/src/algorithms/search/exponential-search/exponentialSearch.js +++ b/src/algorithms/search/exponential-search/exponentialSearch.js @@ -44,7 +44,7 @@ export default function exponentialSearch(sortedArray, seekElement, comparatorCa if (sortedArray.length !== 0) { if (comparator.equal(sortedArray[0], seekElement)){ return 0; - } + } } // Find range for binary search by repeated doubling let range = 1;