Bubble Sort
Last updated
Was this helpful?
Last updated
Was this helpful?
A bubble sort is one of the simplest sorts to write. The idea behind a bubble sort is to start at the beginning of the array and swap adjacent elements that are not in order. Repeat this n-1 times where n is the size of the array and the array will be sorted.