Skip to content

Instantly share code, notes, and snippets.

@satyr
Forked from yuya-takeyama/README.md
Created May 20, 2011 17:37
Show Gist options
  • Save satyr/983385 to your computer and use it in GitHub Desktop.
Save satyr/983385 to your computer and use it in GitHub Desktop.
quick sleep sort

quick sleep sort

example usage:

$ coffee quicksleepsort.coffee 3701 45 292 9 324 45 23 123 1343
9
23
45
45
123
292
324
1343
3701
sleepsort = (list, callback = console.log) ->
setTimeout callback, i, i for i in list
undefined
sleepsort process.argv.slice 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment