Bubble Sort, Bubble Sort Algorithm, Data Structure Algorithm, Dsa Courses, Naem Azam.
arr[j] > arr[j+1] : #Swapping arr[j], arr[j+1] = arr[j+1], arr[j] flag = True if flag is False: break; # Driver code arr = [64, 34, 25, 12, 22, 11, 90] #Printing original array print("Original Array : ", arr) #Calling Function bubbleSort(arr) #Printing Sorted Array print ("Final Sorted array : ",