0
2.1kviews
Sort the following array using each of the three sorting algorithms 26,48,12,92,28,6,33 1)Bubble Sort 2)Insertion Sort 3)Selection Sort
1 Answer
| written 3.8 years ago by |
Algorithm for Bubble Sort:
Step 1 − Starting from the first position of the array, compare the first and the second elements.
Step 2 − If the first element is greater than the second element, they are swapped otherwise no need to swap.
Step 3 − Then …