You are viewing a single comment's thread. Return to all comments →
my code in python:
`left = [i for i in arr[1:] if arr[0] >= i] right = [i for i in arr[1:] if arr[0] < i] left.append(arr[0]) return left + right
`
Seems like cookies are disabled on this browser, please enable them to open this website
Quicksort 1 - Partition
You are viewing a single comment's thread. Return to all comments →
my code in python:
`left = [i for i in arr[1:] if arr[0] >= i] right = [i for i in arr[1:] if arr[0] < i] left.append(arr[0]) return left + right
`