Created
March 22, 2018 07:21
-
-
Save firaja/a8b772a422c02183744aae9417c62b4c to your computer and use it in GitHub Desktop.
Python one line Quicksort algorithm
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
qs = lambda l: [] if not l else qs(filter(lambda x: x <= l[0], l[1:])) + [l[0]] + qs(filter(lambda x: x > l[0], l[1:])) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment