20 lines
461 B
C++
20 lines
461 B
C++
// Задача 11 — куча: heapify за O(n), kth_largest, top_k.
|
|
// Реализуй функции ниже. Заглушка намеренно не проходит проверку.
|
|
#include <vector>
|
|
|
|
void heapify(std::vector<int>& a) {
|
|
(void)a;
|
|
}
|
|
|
|
int kth_largest(const std::vector<int>& a, int k) {
|
|
(void)a;
|
|
(void)k;
|
|
return 0;
|
|
}
|
|
|
|
std::vector<int> top_k(const std::vector<int>& a, int k) {
|
|
(void)a;
|
|
(void)k;
|
|
return {};
|
|
}
|