Files
obsidian-notes/InBox/算法/TopK 问题.md
2025-06-11 18:37:23 +08:00

7 lines
330 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

地址:[前端进阶算法10别再说你不懂topk问题了 · Issue #73 · sisterAn/JavaScript-Algorithms (github.com)](https://github.com/sisterAn/JavaScript-Algorithms/issues/73)
解法:
1、最小最大堆
2、快速选择(快速排序+快速选择时基准恰好等于K时)
3、中位数的中位数BFPRT算法