Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Quicksort
const sort = a => a.length < 1 ? a : [...sort(a.filter(x => x < a[0])), ...a.filter(x => x == a[0]), ...sort(a.filter(x => x > a[0]))]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.