Skip to content

Commit 7d92d96

Browse files
committed
Merge pull request #42 from JensRantil/minor-iteration-fix
fix: improve "key in list" code comment
2 parents 01e541b + 1a56fbf commit 7d92d96

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/performance/using_key_in_list_to_check_if_key_is_contained_in_a_list.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ The code below defines a list ``l`` and then calls ``if 3 in l`` to check if the
1212
1313
l = [1, 2, 3, 4]
1414
15-
if 3 in l: # iterates through list three times
15+
if 3 in l: # iterates over three elements in the list
1616
print "The number 3 is in the list."
1717
else:
1818
print "The number 3 is NOT in the list."

0 commit comments

Comments
 (0)