Skip to content

Commit 9b04759

Browse files
authored
Update bubble_sort.py
1 parent 308286c commit 9b04759

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sorting Algorithms/bubble_sort.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#Link to problem:-
1+
22
#Bubble sort is a sorting algorithm. Sorting algorithms are used to arrange the array in particular order.In,Bubble sort larger elements are pushed at the end of array in each iteration.It works by repeatedly swapping the adjacent elements if they are in wrong order.
33

44
def bubbleSort(a):
@@ -26,4 +26,4 @@ def bubbleSort(a):
2626
print(arr[i])
2727

2828
#Time complexity - O(n^2)
29-
#Space complexity - O(1)
29+
#Space complexity - O(1)

0 commit comments

Comments
 (0)