In computer science, bogosort (also stupid sort, slowsort, random sort, shotgun sort or monkey sort ) is a particularly ineffective sorting algorithm based on the generate and test paradigm. It is not useful for sorting, but may be used for ...

Bubble sort, sometimes referred to as sinking sort, is a simple sorting algorithm that repeatedly steps through the list to be sorted, compares each pair of adjacent items and swaps them if they are in the wrong order. The pass through the list is ...

Cocktail sort, also known as bidirectional bubble sort, cocktail shaker sort, shaker sort (which can also refer to a variant of selection sort ), ripple sort, shuffle sort, or shuttle sort, is a variation of bubble sort that is both a stable sorting ...

In computer science, counting sort is an algorithm for sorting a collection of objects according to keys that are small integers ; that is, it is an integer sorting algorithm. It operates by counting the number of objects that have each distinct key ...

In computer programming, heapsort is a comparison-based sorting algorithm. Heapsort can be thought of as an improved selection sort : like that algorithm, it divides its input into a sorted and an unsorted region, and it iteratively shrinks the ...

Insertion sort is a simple sorting algorithm that builds the final sorted array (or list) one item at a time. It is much less efficient on large lists than more advanced algorithms such as quicksort, heapsort, or merge sort. However, insertion sort ...