Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit f0b8185

Browse files
committed
python builtin keyword removed
1 parent 31dbd56 commit f0b8185

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

‎search/binarySearch.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
def binarySearch(list, key):
1+
def binarySearch(l, key):
22
low = 0
3-
high = len(list) - 1
3+
high = len(l) - 1
44
found = False
55
while low <= high and not found:
66
mid = (low + high) // 2
7-
if list[mid] == key:
7+
if l[mid] == key:
88
found = True
9-
elif key < list[mid]:
9+
elif key < l[mid]:
1010
high = mid - 1
1111
else:
1212
low = mid + 1

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /