# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
134577 |
2019-07-23T04:28:20 Z |
임유진(#3241) |
Sushi (JOI16_sushi) |
C++14 |
|
97 ms |
7792 KB |
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 400005;
int X[MAXN], S[MAXN], T[MAXN], P[MAXN];
priority_queue<int> pq;
int main() {
ios::sync_with_stdio(false); cin.tie(0);
int N, Q;
cin >> N >> Q;
for(int i = 0; i < N; i++) cin >> X[i];
for(int i = 0; i < Q; i++) cin >> S[i] >> T[i] >> P[i];
for(int i = 0; i < N; i++) pq.push(X[i]);
for(int i = 0; i < Q; i++) {
pq.push(P[i]);
cout << pq.top() << "\n";
pq.pop();
}
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
3 ms |
504 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
87 ms |
7792 KB |
Output is correct |
2 |
Correct |
74 ms |
7412 KB |
Output is correct |
3 |
Correct |
45 ms |
5484 KB |
Output is correct |
4 |
Correct |
97 ms |
7456 KB |
Output is correct |
5 |
Correct |
89 ms |
7532 KB |
Output is correct |
6 |
Correct |
89 ms |
7436 KB |
Output is correct |
7 |
Correct |
91 ms |
7444 KB |
Output is correct |
8 |
Correct |
91 ms |
7536 KB |
Output is correct |
9 |
Correct |
42 ms |
5488 KB |
Output is correct |
10 |
Correct |
74 ms |
7408 KB |
Output is correct |
11 |
Correct |
43 ms |
5484 KB |
Output is correct |
12 |
Correct |
74 ms |
7408 KB |
Output is correct |
13 |
Correct |
85 ms |
7792 KB |
Output is correct |
14 |
Correct |
75 ms |
7408 KB |
Output is correct |
15 |
Correct |
45 ms |
5484 KB |
Output is correct |
16 |
Correct |
84 ms |
7404 KB |
Output is correct |
17 |
Correct |
90 ms |
7544 KB |
Output is correct |
18 |
Correct |
89 ms |
7408 KB |
Output is correct |
19 |
Correct |
89 ms |
7408 KB |
Output is correct |
20 |
Correct |
88 ms |
7404 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
3 ms |
504 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |