File tree
Expand file treeCollapse file tree1 file changed
+1
-1
lines changed Expand file treeCollapse file tree1 file changed
+1
-1
lines changed Original file line number | Diff line number | Diff line change |
---|
@@ -30,7 +30,7 @@ def bubble_sort(collection):
|
30 | 30 | [-45, -5, -2]
|
31 | 31 | """
|
32 | 32 | length = len(collection)
|
33 |
| -for i in range(length): |
| 33 | +for i in range(length-1): |
34 | 34 | for j in range(length-1):
|
35 | 35 | if collection[j] > collection[j+1]:
|
36 | 36 | collection[j], collection[j+1] = collection[j+1], collection[j]
|
|
You can’t perform that action at this time.
0 commit comments