排序
Data Structures & Algorithms · 8 notes
- Find the K-th Largesthistorical
Find the K-th largest element in an array using sorting or quicksort partitioning.
- Queue Reconstruction by Heighthistorical
Sort first and then insert by position to reconstruct a queue described by height and preceding-person counts.
- Largest Numberhistorical
Rearrange non-negative integers so their concatenation forms the largest integer.
- Sort Colorshistorical
Sort 0, 1, and 2 in place using quicksort, bucket sort, or the move-zeroes idea.
- Median of Two Sorted Arrayshistorical
LeetCode notes on finding the median of two sorted arrays by merging them.
- Shortest Unsorted Continuous Subarrayhistorical
LeetCode notes on finding the shortest continuous subarray that must be sorted.