The Bubble Sort (O(N^2)) is, on average, the worst of the sorting algorithms which were designed with good things in mind. For specific cases in which the data are already sorted, or almost sorted, bubble sort is by far the fastest sort.