0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-12-26 16:12:11 +00:00
OI-codes/Luogu/P7072/P7072.cpp

16 lines
330 B
C++
Raw Normal View History

2020-11-14 14:14:22 +00:00
#include <bits/stdc++.h>
using namespace std;
int main() {
2021-11-19 09:01:13 +00:00
int n, w, t;
2020-11-14 14:14:22 +00:00
vector<int> score;
cin >> n >> w;
for (int i = 1; i <= n; i++) {
cin >> t;
score.insert(lower_bound(score.begin(), score.end(), t), t);
cout << score[score.size() - max(1, i * w / 100)] << ' ';
}
return 0;
}