Skip to content

Commit 6afac77

Browse files
authored
Update bubble_sort.py
1 parent b01461a commit 6afac77

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/python/bubble_sort.py

+5-5
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ def bubble_sort(data, size):
88
Arguments:
99
data: list. List to be sorted
1010
size: int. List size
11-
11+
1212
Returns the ordered "date" list.
1313
"""
1414
swap = False
@@ -21,7 +21,7 @@ def bubble_sort(data, size):
2121

2222

2323
if __name__ == "__main__":
24-
unordered_list = [2, 9, 8, 0, 1, 3, 5, 4, 6, 7]
25-
print(unordered_list)
26-
bubble_sort(unordered_list, len(unordered_list))
27-
print(unordered_list)
24+
data = [2, 9, 8, 0, 1, 3, 5, 4, 6, 7]
25+
print(data)
26+
bubble_sort(data, len(data))
27+
print(data)

0 commit comments

Comments
 (0)