# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
734362 |
2023-05-02T10:26:05 Z |
QwertyPi |
IOI Fever (JOI21_fever) |
C++14 |
|
5000 ms |
60560 KB |
#include <bits/stdc++.h>
using namespace std;
int dx[4] = {1, -1, 0, 0};
int dy[4] = {0, 0, 1, -1};
const int INF = 1 << 30;
struct point{
int x, y, d, id;
};
vector<point> P;
int front(set<pair<int, int>>& s){
if(s.empty()) return -1;
return s.begin()->second;
}
int back(set<pair<int, int>>& s){
if(s.empty()) return -1;
return (--s.end())->second;
}
int collide(int a, int b){
if(P[a].d == P[b].d) return INF;
if((P[a].d ^ P[b].d) == 1){
switch(P[a].d){
case 0: return P[a].y == P[b].y && P[a].x < P[b].x ? (P[b].x - P[a].x) / 2 : INF;
case 1: return P[a].y == P[b].y && P[b].x < P[a].x ? (P[a].x - P[b].x) / 2 : INF;
case 2: return P[a].x == P[b].x && P[a].y < P[b].y ? (P[b].y - P[a].y) / 2 : INF;
case 3: return P[a].x == P[b].x && P[b].y < P[a].y ? (P[a].y - P[b].y) / 2 : INF;
}
return INF;
}
if(abs(P[a].x - P[b].x) != abs(P[a].y - P[b].y)) return INF;
int D = abs(P[a].x - P[b].x);
if(P[a].x + P[a].y == P[b].x + P[b].y){
if(P[a].x > P[b].x) swap(a, b);
if((P[a].d == 0 && P[b].d == 2) || (P[a].d == 3 && P[b].d == 1)) return D;
return INF;
}else{
if(P[a].x > P[b].x) swap(a, b);
if((P[a].d == 0 && P[b].d == 3) || (P[a].d == 2 && P[b].d == 1)) return D;
return INF;
}
}
int calc(){
map<int, set<pair<int, int>>> X[4], Y[4], A[4], M[4];
for(auto p : P){
X[p.d][p.x].insert({p.y, p.id});
Y[p.d][p.y].insert({p.x, p.id});
A[p.d][p.x + p.y].insert({p.x - p.y, p.id});
M[p.d][p.x - p.y].insert({p.x + p.y, p.id});
}
vector<int> T(P.size(), INF);
auto erase = [&](int id, int t){
auto& p = P[id]; T[id] = t;
X[p.d][p.x].erase({p.y, p.id});
Y[p.d][p.y].erase({p.x, p.id});
A[p.d][p.x + p.y].erase({p.x - p.y, p.id});
M[p.d][p.x - p.y].erase({p.x + p.y, p.id});
};
auto check = [&](int d, set<pair<int, int>>& s, int t){
int id, timer;
while(id = front(X[d][P[t].x]), timer = collide(id, t), timer != INF) erase(id, timer);
while(id = back(X[d][P[t].x]), timer = collide(id, t), timer != INF) erase(id, timer);
};
priority_queue<pair<int, int>, vector<pair<int, int>>, greater<pair<int, int>>> pq; pq.push({0, 0}); T[0] = 0;
while(!pq.empty()){
auto [t, v] = pq.top(); pq.pop();
if(T[v] != t) continue;
for(int i = 0; i < P.size(); i++){
int nt = collide(v, i);
if(T[v] <= nt && nt < T[i]){
T[i] = nt; pq.push({nt, i});
}
}
}
int ans = 0;
for(int i = 0; i < P.size(); i++){
if(T[i] != INF){
ans++;
}
}
return ans;
}
int32_t main(){
int n; cin >> n;
for(int i = 0; i < n; i++){
int x, y; cin >> x >> y; x *= 2, y *= 2;
P.push_back({x, y, 0, i});
}
int ans = 0;
for(int d0 = 0; d0 < 4; d0++){
P[0].d = d0;
for(int i = 1; i < n; i++){
P[i].d = -1;
int dx = P[i].x - P[0].x;
int dy = P[i].y - P[0].y;
if(dx == 0){
P[i].d = 2 ^ (dy > 0);
}else if(dy == 0){
P[i].d = 0 ^ (dx > 0);
}else{
if(abs(dx) < abs(dy)){
P[i].d = 2 ^ (dy > 0);
}else if(abs(dy) < abs(dx)){
P[i].d = 0 ^ (dx > 0);
}else{
if(P[0].d == 0 || P[0].d == 1) {
if((P[0].d == 0) == (dx > 0)) P[i].d = 2 ^ (dy > 0);
else P[i].d = P[0].d;
}
if(P[0].d == 2 || P[0].d == 3) {
if((P[0].d == 2) == (dy > 0)) P[i].d = 0 ^ (dx > 0);
else P[i].d = P[0].d;
}
}
}
assert(P[i].d != -1);
}
ans = max(ans, calc());
}
cout << ans << endl;
}
Compilation message
fever.cpp: In function 'int calc()':
fever.cpp:74:8: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
74 | auto [t, v] = pq.top(); pq.pop();
| ^
fever.cpp:76:20: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<point>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
76 | for(int i = 0; i < P.size(); i++){
| ~~^~~~~~~~~~
fever.cpp:84:19: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<point>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
84 | for(int i = 0; i < P.size(); i++){
| ~~^~~~~~~~~~
fever.cpp:66:7: warning: variable 'check' set but not used [-Wunused-but-set-variable]
66 | auto check = [&](int d, set<pair<int, int>>& s, int t){
| ^~~~~
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
300 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
304 KB |
Output is correct |
5 |
Correct |
0 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
304 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
300 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
300 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
296 KB |
Output is correct |
24 |
Correct |
1 ms |
212 KB |
Output is correct |
25 |
Correct |
1 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
212 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
304 KB |
Output is correct |
31 |
Correct |
1 ms |
296 KB |
Output is correct |
32 |
Correct |
1 ms |
296 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
300 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
304 KB |
Output is correct |
5 |
Correct |
0 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
304 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
300 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
300 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
296 KB |
Output is correct |
24 |
Correct |
1 ms |
212 KB |
Output is correct |
25 |
Correct |
1 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
212 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
304 KB |
Output is correct |
31 |
Correct |
1 ms |
296 KB |
Output is correct |
32 |
Correct |
1 ms |
296 KB |
Output is correct |
33 |
Correct |
1 ms |
304 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
296 KB |
Output is correct |
36 |
Correct |
1 ms |
300 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
308 KB |
Output is correct |
41 |
Correct |
1 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
296 KB |
Output is correct |
43 |
Correct |
1 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
212 KB |
Output is correct |
45 |
Correct |
1 ms |
296 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
304 KB |
Output is correct |
2 |
Correct |
1 ms |
300 KB |
Output is correct |
3 |
Correct |
1 ms |
340 KB |
Output is correct |
4 |
Correct |
1 ms |
300 KB |
Output is correct |
5 |
Correct |
1 ms |
340 KB |
Output is correct |
6 |
Correct |
1 ms |
340 KB |
Output is correct |
7 |
Correct |
2 ms |
340 KB |
Output is correct |
8 |
Correct |
1 ms |
340 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
300 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
304 KB |
Output is correct |
5 |
Correct |
0 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
304 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
300 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
300 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
296 KB |
Output is correct |
24 |
Correct |
1 ms |
212 KB |
Output is correct |
25 |
Correct |
1 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
212 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
304 KB |
Output is correct |
31 |
Correct |
1 ms |
296 KB |
Output is correct |
32 |
Correct |
1 ms |
296 KB |
Output is correct |
33 |
Correct |
1 ms |
304 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
296 KB |
Output is correct |
36 |
Correct |
1 ms |
300 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
308 KB |
Output is correct |
41 |
Correct |
1 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
296 KB |
Output is correct |
43 |
Correct |
1 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
212 KB |
Output is correct |
45 |
Correct |
1 ms |
296 KB |
Output is correct |
46 |
Correct |
1 ms |
304 KB |
Output is correct |
47 |
Correct |
1 ms |
300 KB |
Output is correct |
48 |
Correct |
1 ms |
340 KB |
Output is correct |
49 |
Correct |
1 ms |
300 KB |
Output is correct |
50 |
Correct |
1 ms |
340 KB |
Output is correct |
51 |
Correct |
1 ms |
340 KB |
Output is correct |
52 |
Correct |
2 ms |
340 KB |
Output is correct |
53 |
Correct |
1 ms |
340 KB |
Output is correct |
54 |
Correct |
1 ms |
296 KB |
Output is correct |
55 |
Correct |
1 ms |
340 KB |
Output is correct |
56 |
Correct |
1 ms |
300 KB |
Output is correct |
57 |
Correct |
1 ms |
296 KB |
Output is correct |
58 |
Correct |
2 ms |
300 KB |
Output is correct |
59 |
Correct |
1 ms |
340 KB |
Output is correct |
60 |
Correct |
2 ms |
300 KB |
Output is correct |
61 |
Correct |
1 ms |
340 KB |
Output is correct |
62 |
Correct |
1 ms |
296 KB |
Output is correct |
63 |
Correct |
1 ms |
340 KB |
Output is correct |
64 |
Correct |
1 ms |
340 KB |
Output is correct |
65 |
Correct |
1 ms |
340 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
300 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
304 KB |
Output is correct |
5 |
Correct |
0 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
304 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
300 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
300 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
296 KB |
Output is correct |
24 |
Correct |
1 ms |
212 KB |
Output is correct |
25 |
Correct |
1 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
212 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
304 KB |
Output is correct |
31 |
Correct |
1 ms |
296 KB |
Output is correct |
32 |
Correct |
1 ms |
296 KB |
Output is correct |
33 |
Correct |
1 ms |
304 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
296 KB |
Output is correct |
36 |
Correct |
1 ms |
300 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
308 KB |
Output is correct |
41 |
Correct |
1 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
296 KB |
Output is correct |
43 |
Correct |
1 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
212 KB |
Output is correct |
45 |
Correct |
1 ms |
296 KB |
Output is correct |
46 |
Correct |
1 ms |
304 KB |
Output is correct |
47 |
Correct |
1 ms |
300 KB |
Output is correct |
48 |
Correct |
1 ms |
340 KB |
Output is correct |
49 |
Correct |
1 ms |
300 KB |
Output is correct |
50 |
Correct |
1 ms |
340 KB |
Output is correct |
51 |
Correct |
1 ms |
340 KB |
Output is correct |
52 |
Correct |
2 ms |
340 KB |
Output is correct |
53 |
Correct |
1 ms |
340 KB |
Output is correct |
54 |
Correct |
1 ms |
296 KB |
Output is correct |
55 |
Correct |
1 ms |
340 KB |
Output is correct |
56 |
Correct |
1 ms |
300 KB |
Output is correct |
57 |
Correct |
1 ms |
296 KB |
Output is correct |
58 |
Correct |
2 ms |
300 KB |
Output is correct |
59 |
Correct |
1 ms |
340 KB |
Output is correct |
60 |
Correct |
2 ms |
300 KB |
Output is correct |
61 |
Correct |
1 ms |
340 KB |
Output is correct |
62 |
Correct |
1 ms |
296 KB |
Output is correct |
63 |
Correct |
1 ms |
340 KB |
Output is correct |
64 |
Correct |
1 ms |
340 KB |
Output is correct |
65 |
Correct |
1 ms |
340 KB |
Output is correct |
66 |
Correct |
15 ms |
1912 KB |
Output is correct |
67 |
Correct |
16 ms |
1912 KB |
Output is correct |
68 |
Correct |
18 ms |
2100 KB |
Output is correct |
69 |
Correct |
321 ms |
1220 KB |
Output is correct |
70 |
Correct |
138 ms |
1208 KB |
Output is correct |
71 |
Correct |
39 ms |
1316 KB |
Output is correct |
72 |
Correct |
15 ms |
1848 KB |
Output is correct |
73 |
Correct |
17 ms |
2048 KB |
Output is correct |
74 |
Correct |
65 ms |
1840 KB |
Output is correct |
75 |
Correct |
162 ms |
1872 KB |
Output is correct |
76 |
Correct |
68 ms |
1964 KB |
Output is correct |
77 |
Correct |
52 ms |
1784 KB |
Output is correct |
78 |
Correct |
55 ms |
1972 KB |
Output is correct |
79 |
Correct |
65 ms |
2084 KB |
Output is correct |
80 |
Correct |
27 ms |
2004 KB |
Output is correct |
81 |
Correct |
59 ms |
2004 KB |
Output is correct |
82 |
Correct |
80 ms |
1860 KB |
Output is correct |
83 |
Correct |
123 ms |
1868 KB |
Output is correct |
84 |
Correct |
26 ms |
1400 KB |
Output is correct |
85 |
Correct |
15 ms |
952 KB |
Output is correct |
86 |
Correct |
30 ms |
1036 KB |
Output is correct |
87 |
Correct |
19 ms |
1208 KB |
Output is correct |
88 |
Correct |
77 ms |
1864 KB |
Output is correct |
89 |
Correct |
114 ms |
2100 KB |
Output is correct |
90 |
Correct |
114 ms |
2088 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
300 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
304 KB |
Output is correct |
5 |
Correct |
0 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
304 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
300 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
300 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
296 KB |
Output is correct |
24 |
Correct |
1 ms |
212 KB |
Output is correct |
25 |
Correct |
1 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
212 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
304 KB |
Output is correct |
31 |
Correct |
1 ms |
296 KB |
Output is correct |
32 |
Correct |
1 ms |
296 KB |
Output is correct |
33 |
Correct |
1 ms |
304 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
296 KB |
Output is correct |
36 |
Correct |
1 ms |
300 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
308 KB |
Output is correct |
41 |
Correct |
1 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
296 KB |
Output is correct |
43 |
Correct |
1 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
212 KB |
Output is correct |
45 |
Correct |
1 ms |
296 KB |
Output is correct |
46 |
Correct |
1 ms |
304 KB |
Output is correct |
47 |
Correct |
1 ms |
300 KB |
Output is correct |
48 |
Correct |
1 ms |
340 KB |
Output is correct |
49 |
Correct |
1 ms |
300 KB |
Output is correct |
50 |
Correct |
1 ms |
340 KB |
Output is correct |
51 |
Correct |
1 ms |
340 KB |
Output is correct |
52 |
Correct |
2 ms |
340 KB |
Output is correct |
53 |
Correct |
1 ms |
340 KB |
Output is correct |
54 |
Correct |
1 ms |
296 KB |
Output is correct |
55 |
Correct |
1 ms |
340 KB |
Output is correct |
56 |
Correct |
1 ms |
300 KB |
Output is correct |
57 |
Correct |
1 ms |
296 KB |
Output is correct |
58 |
Correct |
2 ms |
300 KB |
Output is correct |
59 |
Correct |
1 ms |
340 KB |
Output is correct |
60 |
Correct |
2 ms |
300 KB |
Output is correct |
61 |
Correct |
1 ms |
340 KB |
Output is correct |
62 |
Correct |
1 ms |
296 KB |
Output is correct |
63 |
Correct |
1 ms |
340 KB |
Output is correct |
64 |
Correct |
1 ms |
340 KB |
Output is correct |
65 |
Correct |
1 ms |
340 KB |
Output is correct |
66 |
Correct |
1712 ms |
45572 KB |
Output is correct |
67 |
Correct |
2374 ms |
56200 KB |
Output is correct |
68 |
Correct |
2348 ms |
60560 KB |
Output is correct |
69 |
Execution timed out |
5068 ms |
52060 KB |
Time limit exceeded |
70 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
300 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
304 KB |
Output is correct |
5 |
Correct |
0 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
304 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
300 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
300 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
296 KB |
Output is correct |
24 |
Correct |
1 ms |
212 KB |
Output is correct |
25 |
Correct |
1 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
212 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
304 KB |
Output is correct |
31 |
Correct |
1 ms |
296 KB |
Output is correct |
32 |
Correct |
1 ms |
296 KB |
Output is correct |
33 |
Correct |
1 ms |
304 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
296 KB |
Output is correct |
36 |
Correct |
1 ms |
300 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
308 KB |
Output is correct |
41 |
Correct |
1 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
296 KB |
Output is correct |
43 |
Correct |
1 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
212 KB |
Output is correct |
45 |
Correct |
1 ms |
296 KB |
Output is correct |
46 |
Correct |
1 ms |
304 KB |
Output is correct |
47 |
Correct |
1 ms |
300 KB |
Output is correct |
48 |
Correct |
1 ms |
340 KB |
Output is correct |
49 |
Correct |
1 ms |
300 KB |
Output is correct |
50 |
Correct |
1 ms |
340 KB |
Output is correct |
51 |
Correct |
1 ms |
340 KB |
Output is correct |
52 |
Correct |
2 ms |
340 KB |
Output is correct |
53 |
Correct |
1 ms |
340 KB |
Output is correct |
54 |
Correct |
1 ms |
296 KB |
Output is correct |
55 |
Correct |
1 ms |
340 KB |
Output is correct |
56 |
Correct |
1 ms |
300 KB |
Output is correct |
57 |
Correct |
1 ms |
296 KB |
Output is correct |
58 |
Correct |
2 ms |
300 KB |
Output is correct |
59 |
Correct |
1 ms |
340 KB |
Output is correct |
60 |
Correct |
2 ms |
300 KB |
Output is correct |
61 |
Correct |
1 ms |
340 KB |
Output is correct |
62 |
Correct |
1 ms |
296 KB |
Output is correct |
63 |
Correct |
1 ms |
340 KB |
Output is correct |
64 |
Correct |
1 ms |
340 KB |
Output is correct |
65 |
Correct |
1 ms |
340 KB |
Output is correct |
66 |
Correct |
15 ms |
1912 KB |
Output is correct |
67 |
Correct |
16 ms |
1912 KB |
Output is correct |
68 |
Correct |
18 ms |
2100 KB |
Output is correct |
69 |
Correct |
321 ms |
1220 KB |
Output is correct |
70 |
Correct |
138 ms |
1208 KB |
Output is correct |
71 |
Correct |
39 ms |
1316 KB |
Output is correct |
72 |
Correct |
15 ms |
1848 KB |
Output is correct |
73 |
Correct |
17 ms |
2048 KB |
Output is correct |
74 |
Correct |
65 ms |
1840 KB |
Output is correct |
75 |
Correct |
162 ms |
1872 KB |
Output is correct |
76 |
Correct |
68 ms |
1964 KB |
Output is correct |
77 |
Correct |
52 ms |
1784 KB |
Output is correct |
78 |
Correct |
55 ms |
1972 KB |
Output is correct |
79 |
Correct |
65 ms |
2084 KB |
Output is correct |
80 |
Correct |
27 ms |
2004 KB |
Output is correct |
81 |
Correct |
59 ms |
2004 KB |
Output is correct |
82 |
Correct |
80 ms |
1860 KB |
Output is correct |
83 |
Correct |
123 ms |
1868 KB |
Output is correct |
84 |
Correct |
26 ms |
1400 KB |
Output is correct |
85 |
Correct |
15 ms |
952 KB |
Output is correct |
86 |
Correct |
30 ms |
1036 KB |
Output is correct |
87 |
Correct |
19 ms |
1208 KB |
Output is correct |
88 |
Correct |
77 ms |
1864 KB |
Output is correct |
89 |
Correct |
114 ms |
2100 KB |
Output is correct |
90 |
Correct |
114 ms |
2088 KB |
Output is correct |
91 |
Correct |
1712 ms |
45572 KB |
Output is correct |
92 |
Correct |
2374 ms |
56200 KB |
Output is correct |
93 |
Correct |
2348 ms |
60560 KB |
Output is correct |
94 |
Execution timed out |
5068 ms |
52060 KB |
Time limit exceeded |
95 |
Halted |
0 ms |
0 KB |
- |