APETYPE/practice
python·passage intermediate
Desktop Required to Type
Desktop Recommended for Code Typing
ApeType code transcription is engineered for physical mechanical and laptop keyboards with syntax navigation. Mobile on-screen keyboards cannot provide authentic typing cadence.
You can see the leaderboard hereTop Typists
view all1/ 14
1
from typing import List↵
2
↵
3
def quicksort(items: List[int]) -> List[int]:↵
4
if len(items) <= 1:↵
5
return items↵
6
pivot = items[len(items) // 2]↵
7
left = [x for x in items if x < pivot]↵
8
middle = [x for x in items if x == pivot]↵
9
right = [x for x in items if x > pivot]↵
10
return quicksort(left) + middle + quicksort(right)↵
11
↵
12
numbers = [64, 34, 25, 12, 22, 11, 90]↵
13
sorted_list = quicksort(numbers)↵
14
print("Sorted:", sorted_list)
tab+enter- restart
esc- restart