3 ms·
Sounds like quantum bogosort: https://en.wikipedia.org/wiki/Bogosort#Quantum_bogosort https://en.wikipedia.org/wiki/Bogosort#Quantum_bogosort The algorithm gen
by buu700 4y ago
Sounds like quantum bogosort: https://en.wikipedia.org/wiki/Bogosort#Quantum_bogosort https://en.wikipedia.org/wiki/Bogosort#Quantum_bogosort
The algorithm generates a random permutation of its input using a quantum source of entropy, checks if the list is sorted, and, if it is not, destroys the universe. Assuming that the many-worlds interpretation holds, the use of this algorithm will result in at least one surviving universe where the input was successfully sorted in O(n) time.