Skip to content

Instantly share code, notes, and snippets.

@harlanhaskins
Last active August 29, 2015 14:14
Show Gist options
  • Save harlanhaskins/99dbc66f3b08f88c0f23 to your computer and use it in GitHub Desktop.
Save harlanhaskins/99dbc66f3b08f88c0f23 to your computer and use it in GitHub Desktop.
harlanhaskins@nietzsche ~/D/C/P/B/C> ./BogoSort -n 10 -s
[98, 93, 95, 60, 100, 37, 21, 97, 60, 94]
[21, 37, 60, 60, 93, 94, 95, 97, 98, 100]
It took me 00:00:0.458424 to BogoSort this list.
I shuffled it 2,844,195 times.
That's 6204289.042459 shuffles per second.
harlanhaskins@nietzsche ~/D/C/P/B/C> ./BogoSort-Ofast -n 10 -s
[98, 32, 21, 98, 60, 3, 35, 0, 64, 74]
[0, 3, 21, 32, 35, 60, 64, 74, 98, 98]
It took me 00:00:0.221931 to BogoSort this list.
I shuffled it 2,913,137 times.
That's 13126318.540447 shuffles per second.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment