Sorting algorithms/Quicksort: Difference between revisions

m
→‎{{header|Python}}: added <python>
m (→‎{{header|Python}}: added <python>)
Line 558:
a = quickSort(a)
In a Haskell fashion:
<python>
def qsort(L):
return (qsort([y for y in L[1:] if y <= L[0]]) +
L[:1] +
qsort([y for y in L[1:] if y > L[0]])) if len(L) > 1 else L
</python>
 
=={{header|Scheme}}==
A
59

edits