Write a program to implement a bubble sort algorithm on an array.
MediumProblem Statement
Write a program to implement a bubble sort algorithm on an array.
Sample Input
int arr[] = {64, 34, 25, 12, 22, 11, 90};Sample Output
Sorted array: 11 12 22 25 34 64 90
Limits
Time: 2s · Memory: 256 MB