We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 65a5be2 commit 472bcacCopy full SHA for 472bcac
1 file changed
Sorting/Bubble_Sort.py
@@ -13,10 +13,10 @@ def Bubble_sort(arr):
13
#如果swap未標記True,list已完成排序
14
if not swapped:
15
break
16
-
+#main function to test the bubble_sort function
17
if __name__=="__main__":
18
arr=[12,10,9,5,7,2,50,1]
19
print(f"Unsorted list:{arr}")
20
21
Bubble_sort(arr)
22
- print(f"Sorted list:{arr}")
+ print(f"Sorted list(bubble_sort):{arr}")
0 commit comments