Bubble Sort - Visual Representation
5
5
5
5
5
5
5
5
5
5
0
1
2
3
4
5
6
7
8
9
Explanation
Bubble Sort is a simple sorting algorithm that repeatedly steps through the list, compares adjacent elements, and swaps them if they are in the wrong order. This process is repeated until the list is sorted. It's called "bubble sort" because the largest unsorted elements "bubble up" to their correct position with each pass through the list.
Bubble Sort