Skip to content

Commit 213ff55

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 1191e01 commit 213ff55

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

searches/exponential_search.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
Author: Michael Alexander Montoya
1212
"""
1313

14+
1415
def exponential_search(arr, target):
1516
if len(arr) == 0:
1617
return -1
@@ -24,7 +25,7 @@ def exponential_search(arr, target):
2425
index *= 2
2526

2627
# Perform binary search in the found range
27-
return binary_search(arr, target, index // 2, min(index, len(arr)-1))
28+
return binary_search(arr, target, index // 2, min(index, len(arr) - 1))
2829

2930

3031
def binary_search(arr, target, left, right):

0 commit comments

Comments
 (0)