Skip to content

Commit 6891fee

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 52fb458 commit 6891fee

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

searches/binary_search.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -391,10 +391,9 @@ def exponential_search(sorted_collection: list[int], item: int) -> int:
391391
"""
392392
if list(sorted_collection) != sorted(sorted_collection):
393393
raise ValueError(
394-
"Input list must be sorted in ascending order"
395-
"for binary search to work"
394+
"Input list must be sorted in ascending orderfor binary search to work"
396395
)
397-
396+
398397
bound = 1
399398
while bound < len(sorted_collection) and sorted_collection[bound] < item:
400399
bound *= 2

0 commit comments

Comments
 (0)