taco sort


Definition: A terribly inefficient sort algorithm that repeatedly changes a random item by a random amount until a sorted permutation occurs. For an array of n elements of k bits each, the expected run time is n × 2nk.

Generalization (I am a kind of ...)
Las Vegas algorithm.

See also bogosort, bozo sort, stooge sort, lucky sort.

Note: Michael Bernard "came up with tacosort while trying to create an algorithm that is even less efficient than bogosort."

The run time is the same as exhaustive search.

Author: PEB

Go to the Dictionary of Algorithms and Data Structures home page.

If you have suggestions, corrections, or comments, please get in touch with Paul Black.

Entry modified 11 October 2011.
HTML page formatted Wed Mar 13 12:42:46 2019.

Cite this as:
Paul E. Black, "taco sort", in Dictionary of Algorithms and Data Structures [online], Paul E. Black, ed. 11 October 2011. (accessed TODAY) Available from: