Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
0 points
repiret
3y ago
0 comments
Save
Share
Quicksort isn’t stable.
0 comments
2 comments · 1 top-level
top
newest
oldest
orlp
3y ago
· 1 in thread
Schoolbook exchange quicksort isn't stable, but quicksort absolutely can be implemented stably, which I do in glidesort:
https://www.youtube.com/watch?v=2y3IK1l6PI4
.
janwas
3y ago
Further to that, many use cases of Quicksort have unique keys, so stable is the same as unstable. Example: ascending indices appended to the key, when sorting large records where we don't want to move around the entire record.
j
/
k
navigate · click thread line to collapse