Skip to content

Bogo Sort

Aashish Bharadwaj edited this page Mar 17, 2018 · 2 revisions

Average time complexity - O((n + 1)!)

Best-Case time complexity - Θ(n)

Worst-Case time complexity - O(∞)

Worst-case space complexity - O(1)

Bogo Sort just randomly swaps two values in the array, then checks if it is sorted. It repeats this until it is sorted.

Clone this wiki locally