← Skills
Heaps, sorting & intervals
top-k with a heap
Keep a size-k min-heap so the root is the k-th largest.
Builds on: heapq push/pop
—
Unseen
No reps yet
No reps yet.
- Attempts
- 0
- Correct
- 0
- Failed
- 0
- Clean streak
- 0
- Cold
- 0/0
- Hints
- 0
Next review: after your first rep
Recent attempts
No reps yet.