#include<bits/stdc++.h>
#define forin(i,a,b) for(int i=a;i<=b;++i)
using namespace std;
const int N = 6e6 + 10;
int r, c, n, x, y, u, v, dp;
int row[4] = {0, -1, 0, 1};
int col[4] = {1, 0, -1, 0};
string s[N];
vector<vector<int>> f, par1, par2, vis, red;
queue<pair<int, int>> tmp;
void create(vector<vector<int>> &a) {
a.resize(r + 2);
forin(i,1,r + 1) a[i].resize(c + 2);
}
int root1(int i, int j) {
return (par1[i][j] == j) ? j : par1[i][j] = root1(i, par1[i][j]);
}
int root2(int i, int j) {
return (par2[i][j] == i) ? i : par2[i][j] = root2(par2[i][j], j);
}
bool check(int i, int j) {
if(i < 1 || r < i || j < 1 || c < j) return 0;
return 1;
}
void up(int x, int y) {
if(!check(x, y)) return;
if(f[x][y]) return;
f[x][y] = dp + 1;
par1[x][y] = y + 1;
par2[x][y] = x + 1;
tmp.push({x, y});
}
void bfs(int x, int y, queue<pair<int, int>> &p) {
queue<pair<int, int>> q;
q.push({x, y});
while(!q.empty()) {
int x1, y1; tie(x1, y1) = q.front(); q.pop();
f[x1][y1] = dp;
forin(k,0,3) {
int u1 = x1 + row[k];
int v1 = y1 + col[k];
if(!check(u1, v1) || red[u1][v1]) continue;
if(s[u1][v1] != '.' && f[u1][v1] != dp) continue;
red[u1][v1] = 1;
if(s[u1][v1] == '.') up(u1, v1);
p.push({u1, v1});
q.push({u1, v1});
}
}
}
int main () {
cin.tie(0)->sync_with_stdio(0);
if(fopen("Task.inp","r")) {
freopen("Task.inp","r",stdin);
freopen("WA.out","w",stdout);
}
cin>>r>>c>>n;
create(f);
create(vis);
create(red);
cin>>x>>y;
cin>>u>>v;
forin(i,1,r) {
cin>>s[i];
s[i] = " " + s[i];
}
create(par1);
create(par2);
forin(i,1,r + 1) forin(j,1,c + 1) {
par1[i][j] = j;
par2[i][j] = i;
}
up(x, y);
while(true) {
dp++;
queue<pair<int, int>> q;
while(!tmp.empty()) {
int x1, y1; tie(x1, y1) = tmp.front(); tmp.pop();
if(red[x1][y1]) continue;
red[x1][y1] = 1;
q.push({x1, y1});
bfs(x1, y1, q);
}
while(!q.empty()) {
int x1, y1; tie(x1, y1) = q.front(); q.pop();
vis[x1][y1] = 1;
vector<int> vt;
forin(k,0,3) {
int u1 = x1 + row[k];
int v1 = y1 + col[k];
if(!check(u1, v1) || !vis[u1][v1]) continue;
vt.push_back(k);
}
if(vt.empty()) {
forin(i,-n,n) forin(j,-n,n) if(!(abs(i) == n && abs(j) == n) && check(x1 + i, y1 + j)) {
up(x1 + i, y1 + j);
}
}
else if(vt.size() == 1) {
int k = vt[0];
int t = - (row[k] + col[k]);
if(row[k]) {
up(x1 + t * (n - 1), y1 + n);
up(x1 + t * (n - 1), y1 - n);
int u1 = x1 + t * n;
int v1 = max(1, y1 - n + 1);
if(!check(u1, v1)) continue;
while(true) {
v1 = root1(u1, v1);
if(v1 > min(c, y1 + n - 1)) break;
up(u1, v1);
}
}
else {
up(x1 + n, y1 + t * (n - 1));
up(x1 - n, y1 + t * (n - 1));
int u1 = max(1, x1 - n + 1);
int v1 = y1 + t * n;
if(!check(u1, v1)) continue;
while(true) {
u1 = root2(u1, v1);
if(u1 > min(r, x1 + n - 1)) break;
up(u1, v1);
}
}
}
else if(vt.size() == 2 && (vt[0] - vt[1]) % 2) {
if(vt[0] % 2) swap(vt[0], vt[1]);
int t1 = - (row[vt[1]] + col[vt[1]]);
int t2 = - (row[vt[0]] + col[vt[0]]);
up(x1 + t1 * (n - 1), y1 + n);
up(x1 + t1 * (n - 1), y1 - n);
up(x1 + n, y1 + t2 * (n - 1));
up(x1 - n, y1 + t2 * (n - 1));
}
else {
forin(k,0,3) up(x1 + row[k] * n, y1 + col[k] * n);
}
}
if(f[u][v]) return cout<<f[u][v] - 1, 0;
}
}
Compilation message
Main.cpp: In function 'int main()':
Main.cpp:54:16: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
54 | freopen("Task.inp","r",stdin);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
Main.cpp:55:16: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
55 | freopen("WA.out","w",stdout);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
86 ms |
188104 KB |
Output is correct |
2 |
Correct |
87 ms |
188164 KB |
Output is correct |
3 |
Correct |
88 ms |
188200 KB |
Output is correct |
4 |
Correct |
85 ms |
188108 KB |
Output is correct |
5 |
Correct |
90 ms |
188172 KB |
Output is correct |
6 |
Correct |
86 ms |
188164 KB |
Output is correct |
7 |
Correct |
85 ms |
188216 KB |
Output is correct |
8 |
Correct |
90 ms |
188192 KB |
Output is correct |
9 |
Correct |
86 ms |
188104 KB |
Output is correct |
10 |
Correct |
90 ms |
188168 KB |
Output is correct |
11 |
Correct |
86 ms |
188080 KB |
Output is correct |
12 |
Correct |
101 ms |
188044 KB |
Output is correct |
13 |
Correct |
99 ms |
188164 KB |
Output is correct |
14 |
Correct |
93 ms |
188056 KB |
Output is correct |
15 |
Correct |
91 ms |
188168 KB |
Output is correct |
16 |
Correct |
88 ms |
188140 KB |
Output is correct |
17 |
Correct |
87 ms |
188108 KB |
Output is correct |
18 |
Correct |
86 ms |
188172 KB |
Output is correct |
19 |
Correct |
102 ms |
189424 KB |
Output is correct |
20 |
Correct |
92 ms |
190136 KB |
Output is correct |
21 |
Correct |
97 ms |
190412 KB |
Output is correct |
22 |
Correct |
98 ms |
189504 KB |
Output is correct |
23 |
Correct |
101 ms |
189424 KB |
Output is correct |
24 |
Correct |
92 ms |
190688 KB |
Output is correct |
25 |
Correct |
95 ms |
190772 KB |
Output is correct |
26 |
Correct |
88 ms |
189556 KB |
Output is correct |
27 |
Correct |
88 ms |
189456 KB |
Output is correct |
28 |
Correct |
88 ms |
189428 KB |
Output is correct |
29 |
Correct |
116 ms |
191352 KB |
Output is correct |
30 |
Correct |
96 ms |
190124 KB |
Output is correct |
31 |
Correct |
111 ms |
193828 KB |
Output is correct |
32 |
Correct |
117 ms |
191524 KB |
Output is correct |
33 |
Correct |
120 ms |
191408 KB |
Output is correct |
34 |
Correct |
115 ms |
194372 KB |
Output is correct |
35 |
Correct |
117 ms |
194372 KB |
Output is correct |
36 |
Correct |
104 ms |
191640 KB |
Output is correct |
37 |
Correct |
109 ms |
191436 KB |
Output is correct |
38 |
Correct |
92 ms |
191424 KB |
Output is correct |
39 |
Correct |
429 ms |
219872 KB |
Output is correct |
40 |
Correct |
114 ms |
191940 KB |
Output is correct |
41 |
Correct |
103 ms |
195736 KB |
Output is correct |
42 |
Correct |
141 ms |
192756 KB |
Output is correct |
43 |
Correct |
115 ms |
195712 KB |
Output is correct |
44 |
Correct |
139 ms |
206176 KB |
Output is correct |
45 |
Correct |
153 ms |
208952 KB |
Output is correct |
46 |
Correct |
409 ms |
245176 KB |
Output is correct |
47 |
Correct |
407 ms |
220468 KB |
Output is correct |
48 |
Correct |
378 ms |
220872 KB |
Output is correct |
49 |
Correct |
216 ms |
249928 KB |
Output is correct |
50 |
Correct |
268 ms |
249960 KB |
Output is correct |
51 |
Correct |
332 ms |
221436 KB |
Output is correct |
52 |
Correct |
261 ms |
221092 KB |
Output is correct |
53 |
Correct |
372 ms |
220920 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
99 ms |
188172 KB |
Output is correct |
2 |
Correct |
90 ms |
188080 KB |
Output is correct |
3 |
Correct |
90 ms |
188208 KB |
Output is correct |
4 |
Correct |
85 ms |
188168 KB |
Output is correct |
5 |
Correct |
89 ms |
188144 KB |
Output is correct |
6 |
Correct |
88 ms |
188088 KB |
Output is correct |
7 |
Correct |
85 ms |
188220 KB |
Output is correct |
8 |
Correct |
88 ms |
188148 KB |
Output is correct |
9 |
Correct |
87 ms |
188144 KB |
Output is correct |
10 |
Correct |
88 ms |
188108 KB |
Output is correct |
11 |
Correct |
94 ms |
188104 KB |
Output is correct |
12 |
Correct |
88 ms |
188180 KB |
Output is correct |
13 |
Correct |
89 ms |
188204 KB |
Output is correct |
14 |
Correct |
87 ms |
188160 KB |
Output is correct |
15 |
Correct |
98 ms |
188200 KB |
Output is correct |
16 |
Correct |
88 ms |
188164 KB |
Output is correct |
17 |
Correct |
89 ms |
188208 KB |
Output is correct |
18 |
Correct |
91 ms |
188048 KB |
Output is correct |
19 |
Correct |
88 ms |
188108 KB |
Output is correct |
20 |
Correct |
89 ms |
188092 KB |
Output is correct |
21 |
Correct |
88 ms |
188116 KB |
Output is correct |
22 |
Correct |
90 ms |
188176 KB |
Output is correct |
23 |
Correct |
96 ms |
188108 KB |
Output is correct |
24 |
Correct |
87 ms |
188116 KB |
Output is correct |
25 |
Correct |
89 ms |
188108 KB |
Output is correct |
26 |
Correct |
90 ms |
188096 KB |
Output is correct |
27 |
Correct |
94 ms |
188128 KB |
Output is correct |
28 |
Correct |
91 ms |
188108 KB |
Output is correct |
29 |
Correct |
90 ms |
188108 KB |
Output is correct |
30 |
Correct |
92 ms |
188160 KB |
Output is correct |
31 |
Correct |
86 ms |
188104 KB |
Output is correct |
32 |
Correct |
88 ms |
188200 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
94 ms |
188108 KB |
Output is correct |
2 |
Correct |
99 ms |
188176 KB |
Output is correct |
3 |
Correct |
88 ms |
188136 KB |
Output is correct |
4 |
Correct |
86 ms |
188104 KB |
Output is correct |
5 |
Correct |
87 ms |
188108 KB |
Output is correct |
6 |
Correct |
95 ms |
188112 KB |
Output is correct |
7 |
Correct |
93 ms |
188168 KB |
Output is correct |
8 |
Correct |
88 ms |
188104 KB |
Output is correct |
9 |
Correct |
95 ms |
188216 KB |
Output is correct |
10 |
Correct |
93 ms |
188196 KB |
Output is correct |
11 |
Correct |
91 ms |
188252 KB |
Output is correct |
12 |
Correct |
91 ms |
188224 KB |
Output is correct |
13 |
Correct |
87 ms |
188148 KB |
Output is correct |
14 |
Correct |
95 ms |
188108 KB |
Output is correct |
15 |
Correct |
92 ms |
188084 KB |
Output is correct |
16 |
Correct |
88 ms |
188176 KB |
Output is correct |
17 |
Correct |
90 ms |
188120 KB |
Output is correct |
18 |
Correct |
88 ms |
188172 KB |
Output is correct |
19 |
Correct |
93 ms |
188144 KB |
Output is correct |
20 |
Correct |
90 ms |
188168 KB |
Output is correct |
21 |
Correct |
89 ms |
188116 KB |
Output is correct |
22 |
Correct |
92 ms |
188204 KB |
Output is correct |
23 |
Correct |
89 ms |
188176 KB |
Output is correct |
24 |
Correct |
90 ms |
188104 KB |
Output is correct |
25 |
Correct |
89 ms |
189024 KB |
Output is correct |
26 |
Correct |
97 ms |
190020 KB |
Output is correct |
27 |
Correct |
103 ms |
190396 KB |
Output is correct |
28 |
Correct |
97 ms |
190424 KB |
Output is correct |
29 |
Correct |
91 ms |
189908 KB |
Output is correct |
30 |
Correct |
92 ms |
189932 KB |
Output is correct |
31 |
Correct |
91 ms |
189472 KB |
Output is correct |
32 |
Correct |
92 ms |
189512 KB |
Output is correct |
33 |
Correct |
91 ms |
189664 KB |
Output is correct |
34 |
Correct |
108 ms |
192256 KB |
Output is correct |
35 |
Correct |
111 ms |
193868 KB |
Output is correct |
36 |
Correct |
118 ms |
193864 KB |
Output is correct |
37 |
Correct |
94 ms |
192716 KB |
Output is correct |
38 |
Correct |
94 ms |
192716 KB |
Output is correct |
39 |
Correct |
169 ms |
202764 KB |
Output is correct |
40 |
Correct |
324 ms |
230932 KB |
Output is correct |
41 |
Correct |
454 ms |
245096 KB |
Output is correct |
42 |
Correct |
340 ms |
244968 KB |
Output is correct |
43 |
Correct |
141 ms |
233160 KB |
Output is correct |
44 |
Correct |
158 ms |
233036 KB |
Output is correct |
45 |
Correct |
299 ms |
235828 KB |
Output is correct |
46 |
Correct |
319 ms |
235756 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
99 ms |
188172 KB |
Output is correct |
2 |
Correct |
90 ms |
188080 KB |
Output is correct |
3 |
Correct |
90 ms |
188208 KB |
Output is correct |
4 |
Correct |
85 ms |
188168 KB |
Output is correct |
5 |
Correct |
89 ms |
188144 KB |
Output is correct |
6 |
Correct |
88 ms |
188088 KB |
Output is correct |
7 |
Correct |
85 ms |
188220 KB |
Output is correct |
8 |
Correct |
88 ms |
188148 KB |
Output is correct |
9 |
Correct |
87 ms |
188144 KB |
Output is correct |
10 |
Correct |
88 ms |
188108 KB |
Output is correct |
11 |
Correct |
94 ms |
188104 KB |
Output is correct |
12 |
Correct |
88 ms |
188180 KB |
Output is correct |
13 |
Correct |
89 ms |
188204 KB |
Output is correct |
14 |
Correct |
87 ms |
188160 KB |
Output is correct |
15 |
Correct |
98 ms |
188200 KB |
Output is correct |
16 |
Correct |
88 ms |
188164 KB |
Output is correct |
17 |
Correct |
89 ms |
188208 KB |
Output is correct |
18 |
Correct |
91 ms |
188048 KB |
Output is correct |
19 |
Correct |
88 ms |
188108 KB |
Output is correct |
20 |
Correct |
89 ms |
188092 KB |
Output is correct |
21 |
Correct |
88 ms |
188116 KB |
Output is correct |
22 |
Correct |
90 ms |
188176 KB |
Output is correct |
23 |
Correct |
96 ms |
188108 KB |
Output is correct |
24 |
Correct |
87 ms |
188116 KB |
Output is correct |
25 |
Correct |
89 ms |
188108 KB |
Output is correct |
26 |
Correct |
90 ms |
188096 KB |
Output is correct |
27 |
Correct |
94 ms |
188128 KB |
Output is correct |
28 |
Correct |
91 ms |
188108 KB |
Output is correct |
29 |
Correct |
90 ms |
188108 KB |
Output is correct |
30 |
Correct |
92 ms |
188160 KB |
Output is correct |
31 |
Correct |
86 ms |
188104 KB |
Output is correct |
32 |
Correct |
88 ms |
188200 KB |
Output is correct |
33 |
Correct |
109 ms |
189528 KB |
Output is correct |
34 |
Correct |
101 ms |
188172 KB |
Output is correct |
35 |
Correct |
90 ms |
188236 KB |
Output is correct |
36 |
Correct |
90 ms |
188988 KB |
Output is correct |
37 |
Correct |
98 ms |
190156 KB |
Output is correct |
38 |
Correct |
107 ms |
190068 KB |
Output is correct |
39 |
Correct |
96 ms |
190420 KB |
Output is correct |
40 |
Correct |
102 ms |
189516 KB |
Output is correct |
41 |
Correct |
101 ms |
189468 KB |
Output is correct |
42 |
Correct |
98 ms |
190468 KB |
Output is correct |
43 |
Correct |
92 ms |
189908 KB |
Output is correct |
44 |
Correct |
98 ms |
189960 KB |
Output is correct |
45 |
Correct |
98 ms |
190696 KB |
Output is correct |
46 |
Correct |
100 ms |
190768 KB |
Output is correct |
47 |
Correct |
99 ms |
190000 KB |
Output is correct |
48 |
Correct |
96 ms |
189512 KB |
Output is correct |
49 |
Correct |
94 ms |
189516 KB |
Output is correct |
50 |
Correct |
101 ms |
189472 KB |
Output is correct |
51 |
Correct |
93 ms |
189528 KB |
Output is correct |
52 |
Correct |
102 ms |
189564 KB |
Output is correct |
53 |
Correct |
92 ms |
189480 KB |
Output is correct |
54 |
Correct |
96 ms |
189540 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
99 ms |
188172 KB |
Output is correct |
2 |
Correct |
90 ms |
188080 KB |
Output is correct |
3 |
Correct |
90 ms |
188208 KB |
Output is correct |
4 |
Correct |
85 ms |
188168 KB |
Output is correct |
5 |
Correct |
89 ms |
188144 KB |
Output is correct |
6 |
Correct |
88 ms |
188088 KB |
Output is correct |
7 |
Correct |
85 ms |
188220 KB |
Output is correct |
8 |
Correct |
88 ms |
188148 KB |
Output is correct |
9 |
Correct |
87 ms |
188144 KB |
Output is correct |
10 |
Correct |
88 ms |
188108 KB |
Output is correct |
11 |
Correct |
94 ms |
188104 KB |
Output is correct |
12 |
Correct |
88 ms |
188180 KB |
Output is correct |
13 |
Correct |
89 ms |
188204 KB |
Output is correct |
14 |
Correct |
87 ms |
188160 KB |
Output is correct |
15 |
Correct |
98 ms |
188200 KB |
Output is correct |
16 |
Correct |
88 ms |
188164 KB |
Output is correct |
17 |
Correct |
89 ms |
188208 KB |
Output is correct |
18 |
Correct |
91 ms |
188048 KB |
Output is correct |
19 |
Correct |
88 ms |
188108 KB |
Output is correct |
20 |
Correct |
89 ms |
188092 KB |
Output is correct |
21 |
Correct |
88 ms |
188116 KB |
Output is correct |
22 |
Correct |
90 ms |
188176 KB |
Output is correct |
23 |
Correct |
96 ms |
188108 KB |
Output is correct |
24 |
Correct |
87 ms |
188116 KB |
Output is correct |
25 |
Correct |
89 ms |
188108 KB |
Output is correct |
26 |
Correct |
90 ms |
188096 KB |
Output is correct |
27 |
Correct |
94 ms |
188128 KB |
Output is correct |
28 |
Correct |
91 ms |
188108 KB |
Output is correct |
29 |
Correct |
90 ms |
188108 KB |
Output is correct |
30 |
Correct |
92 ms |
188160 KB |
Output is correct |
31 |
Correct |
86 ms |
188104 KB |
Output is correct |
32 |
Correct |
88 ms |
188200 KB |
Output is correct |
33 |
Correct |
109 ms |
189528 KB |
Output is correct |
34 |
Correct |
101 ms |
188172 KB |
Output is correct |
35 |
Correct |
90 ms |
188236 KB |
Output is correct |
36 |
Correct |
90 ms |
188988 KB |
Output is correct |
37 |
Correct |
98 ms |
190156 KB |
Output is correct |
38 |
Correct |
107 ms |
190068 KB |
Output is correct |
39 |
Correct |
96 ms |
190420 KB |
Output is correct |
40 |
Correct |
102 ms |
189516 KB |
Output is correct |
41 |
Correct |
101 ms |
189468 KB |
Output is correct |
42 |
Correct |
98 ms |
190468 KB |
Output is correct |
43 |
Correct |
92 ms |
189908 KB |
Output is correct |
44 |
Correct |
98 ms |
189960 KB |
Output is correct |
45 |
Correct |
98 ms |
190696 KB |
Output is correct |
46 |
Correct |
100 ms |
190768 KB |
Output is correct |
47 |
Correct |
99 ms |
190000 KB |
Output is correct |
48 |
Correct |
96 ms |
189512 KB |
Output is correct |
49 |
Correct |
94 ms |
189516 KB |
Output is correct |
50 |
Correct |
101 ms |
189472 KB |
Output is correct |
51 |
Correct |
93 ms |
189528 KB |
Output is correct |
52 |
Correct |
102 ms |
189564 KB |
Output is correct |
53 |
Correct |
92 ms |
189480 KB |
Output is correct |
54 |
Correct |
96 ms |
189540 KB |
Output is correct |
55 |
Correct |
122 ms |
191408 KB |
Output is correct |
56 |
Correct |
97 ms |
190016 KB |
Output is correct |
57 |
Correct |
111 ms |
192268 KB |
Output is correct |
58 |
Correct |
113 ms |
191288 KB |
Output is correct |
59 |
Correct |
113 ms |
193876 KB |
Output is correct |
60 |
Correct |
119 ms |
191440 KB |
Output is correct |
61 |
Correct |
114 ms |
191588 KB |
Output is correct |
62 |
Correct |
113 ms |
193868 KB |
Output is correct |
63 |
Correct |
94 ms |
192716 KB |
Output is correct |
64 |
Correct |
100 ms |
192688 KB |
Output is correct |
65 |
Correct |
111 ms |
194500 KB |
Output is correct |
66 |
Correct |
116 ms |
194456 KB |
Output is correct |
67 |
Correct |
116 ms |
192960 KB |
Output is correct |
68 |
Correct |
110 ms |
191484 KB |
Output is correct |
69 |
Correct |
114 ms |
191552 KB |
Output is correct |
70 |
Correct |
124 ms |
191572 KB |
Output is correct |
71 |
Correct |
111 ms |
191676 KB |
Output is correct |
72 |
Correct |
110 ms |
191820 KB |
Output is correct |
73 |
Correct |
124 ms |
191664 KB |
Output is correct |
74 |
Correct |
95 ms |
191448 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
86 ms |
188104 KB |
Output is correct |
2 |
Correct |
87 ms |
188164 KB |
Output is correct |
3 |
Correct |
88 ms |
188200 KB |
Output is correct |
4 |
Correct |
85 ms |
188108 KB |
Output is correct |
5 |
Correct |
90 ms |
188172 KB |
Output is correct |
6 |
Correct |
86 ms |
188164 KB |
Output is correct |
7 |
Correct |
85 ms |
188216 KB |
Output is correct |
8 |
Correct |
90 ms |
188192 KB |
Output is correct |
9 |
Correct |
86 ms |
188104 KB |
Output is correct |
10 |
Correct |
90 ms |
188168 KB |
Output is correct |
11 |
Correct |
86 ms |
188080 KB |
Output is correct |
12 |
Correct |
101 ms |
188044 KB |
Output is correct |
13 |
Correct |
99 ms |
188164 KB |
Output is correct |
14 |
Correct |
93 ms |
188056 KB |
Output is correct |
15 |
Correct |
91 ms |
188168 KB |
Output is correct |
16 |
Correct |
88 ms |
188140 KB |
Output is correct |
17 |
Correct |
87 ms |
188108 KB |
Output is correct |
18 |
Correct |
86 ms |
188172 KB |
Output is correct |
19 |
Correct |
102 ms |
189424 KB |
Output is correct |
20 |
Correct |
92 ms |
190136 KB |
Output is correct |
21 |
Correct |
97 ms |
190412 KB |
Output is correct |
22 |
Correct |
98 ms |
189504 KB |
Output is correct |
23 |
Correct |
101 ms |
189424 KB |
Output is correct |
24 |
Correct |
92 ms |
190688 KB |
Output is correct |
25 |
Correct |
95 ms |
190772 KB |
Output is correct |
26 |
Correct |
88 ms |
189556 KB |
Output is correct |
27 |
Correct |
88 ms |
189456 KB |
Output is correct |
28 |
Correct |
88 ms |
189428 KB |
Output is correct |
29 |
Correct |
116 ms |
191352 KB |
Output is correct |
30 |
Correct |
96 ms |
190124 KB |
Output is correct |
31 |
Correct |
111 ms |
193828 KB |
Output is correct |
32 |
Correct |
117 ms |
191524 KB |
Output is correct |
33 |
Correct |
120 ms |
191408 KB |
Output is correct |
34 |
Correct |
115 ms |
194372 KB |
Output is correct |
35 |
Correct |
117 ms |
194372 KB |
Output is correct |
36 |
Correct |
104 ms |
191640 KB |
Output is correct |
37 |
Correct |
109 ms |
191436 KB |
Output is correct |
38 |
Correct |
92 ms |
191424 KB |
Output is correct |
39 |
Correct |
429 ms |
219872 KB |
Output is correct |
40 |
Correct |
114 ms |
191940 KB |
Output is correct |
41 |
Correct |
103 ms |
195736 KB |
Output is correct |
42 |
Correct |
141 ms |
192756 KB |
Output is correct |
43 |
Correct |
115 ms |
195712 KB |
Output is correct |
44 |
Correct |
139 ms |
206176 KB |
Output is correct |
45 |
Correct |
153 ms |
208952 KB |
Output is correct |
46 |
Correct |
409 ms |
245176 KB |
Output is correct |
47 |
Correct |
407 ms |
220468 KB |
Output is correct |
48 |
Correct |
378 ms |
220872 KB |
Output is correct |
49 |
Correct |
216 ms |
249928 KB |
Output is correct |
50 |
Correct |
268 ms |
249960 KB |
Output is correct |
51 |
Correct |
332 ms |
221436 KB |
Output is correct |
52 |
Correct |
261 ms |
221092 KB |
Output is correct |
53 |
Correct |
372 ms |
220920 KB |
Output is correct |
54 |
Correct |
99 ms |
188172 KB |
Output is correct |
55 |
Correct |
90 ms |
188080 KB |
Output is correct |
56 |
Correct |
90 ms |
188208 KB |
Output is correct |
57 |
Correct |
85 ms |
188168 KB |
Output is correct |
58 |
Correct |
89 ms |
188144 KB |
Output is correct |
59 |
Correct |
88 ms |
188088 KB |
Output is correct |
60 |
Correct |
85 ms |
188220 KB |
Output is correct |
61 |
Correct |
88 ms |
188148 KB |
Output is correct |
62 |
Correct |
87 ms |
188144 KB |
Output is correct |
63 |
Correct |
88 ms |
188108 KB |
Output is correct |
64 |
Correct |
94 ms |
188104 KB |
Output is correct |
65 |
Correct |
88 ms |
188180 KB |
Output is correct |
66 |
Correct |
89 ms |
188204 KB |
Output is correct |
67 |
Correct |
87 ms |
188160 KB |
Output is correct |
68 |
Correct |
98 ms |
188200 KB |
Output is correct |
69 |
Correct |
88 ms |
188164 KB |
Output is correct |
70 |
Correct |
89 ms |
188208 KB |
Output is correct |
71 |
Correct |
91 ms |
188048 KB |
Output is correct |
72 |
Correct |
88 ms |
188108 KB |
Output is correct |
73 |
Correct |
89 ms |
188092 KB |
Output is correct |
74 |
Correct |
88 ms |
188116 KB |
Output is correct |
75 |
Correct |
90 ms |
188176 KB |
Output is correct |
76 |
Correct |
96 ms |
188108 KB |
Output is correct |
77 |
Correct |
87 ms |
188116 KB |
Output is correct |
78 |
Correct |
89 ms |
188108 KB |
Output is correct |
79 |
Correct |
90 ms |
188096 KB |
Output is correct |
80 |
Correct |
94 ms |
188128 KB |
Output is correct |
81 |
Correct |
91 ms |
188108 KB |
Output is correct |
82 |
Correct |
90 ms |
188108 KB |
Output is correct |
83 |
Correct |
92 ms |
188160 KB |
Output is correct |
84 |
Correct |
86 ms |
188104 KB |
Output is correct |
85 |
Correct |
88 ms |
188200 KB |
Output is correct |
86 |
Correct |
94 ms |
188108 KB |
Output is correct |
87 |
Correct |
99 ms |
188176 KB |
Output is correct |
88 |
Correct |
88 ms |
188136 KB |
Output is correct |
89 |
Correct |
86 ms |
188104 KB |
Output is correct |
90 |
Correct |
87 ms |
188108 KB |
Output is correct |
91 |
Correct |
95 ms |
188112 KB |
Output is correct |
92 |
Correct |
93 ms |
188168 KB |
Output is correct |
93 |
Correct |
88 ms |
188104 KB |
Output is correct |
94 |
Correct |
95 ms |
188216 KB |
Output is correct |
95 |
Correct |
93 ms |
188196 KB |
Output is correct |
96 |
Correct |
91 ms |
188252 KB |
Output is correct |
97 |
Correct |
91 ms |
188224 KB |
Output is correct |
98 |
Correct |
87 ms |
188148 KB |
Output is correct |
99 |
Correct |
95 ms |
188108 KB |
Output is correct |
100 |
Correct |
92 ms |
188084 KB |
Output is correct |
101 |
Correct |
88 ms |
188176 KB |
Output is correct |
102 |
Correct |
90 ms |
188120 KB |
Output is correct |
103 |
Correct |
88 ms |
188172 KB |
Output is correct |
104 |
Correct |
93 ms |
188144 KB |
Output is correct |
105 |
Correct |
90 ms |
188168 KB |
Output is correct |
106 |
Correct |
89 ms |
188116 KB |
Output is correct |
107 |
Correct |
92 ms |
188204 KB |
Output is correct |
108 |
Correct |
89 ms |
188176 KB |
Output is correct |
109 |
Correct |
90 ms |
188104 KB |
Output is correct |
110 |
Correct |
89 ms |
189024 KB |
Output is correct |
111 |
Correct |
97 ms |
190020 KB |
Output is correct |
112 |
Correct |
103 ms |
190396 KB |
Output is correct |
113 |
Correct |
97 ms |
190424 KB |
Output is correct |
114 |
Correct |
91 ms |
189908 KB |
Output is correct |
115 |
Correct |
92 ms |
189932 KB |
Output is correct |
116 |
Correct |
91 ms |
189472 KB |
Output is correct |
117 |
Correct |
92 ms |
189512 KB |
Output is correct |
118 |
Correct |
91 ms |
189664 KB |
Output is correct |
119 |
Correct |
108 ms |
192256 KB |
Output is correct |
120 |
Correct |
111 ms |
193868 KB |
Output is correct |
121 |
Correct |
118 ms |
193864 KB |
Output is correct |
122 |
Correct |
94 ms |
192716 KB |
Output is correct |
123 |
Correct |
94 ms |
192716 KB |
Output is correct |
124 |
Correct |
169 ms |
202764 KB |
Output is correct |
125 |
Correct |
324 ms |
230932 KB |
Output is correct |
126 |
Correct |
454 ms |
245096 KB |
Output is correct |
127 |
Correct |
340 ms |
244968 KB |
Output is correct |
128 |
Correct |
141 ms |
233160 KB |
Output is correct |
129 |
Correct |
158 ms |
233036 KB |
Output is correct |
130 |
Correct |
299 ms |
235828 KB |
Output is correct |
131 |
Correct |
319 ms |
235756 KB |
Output is correct |
132 |
Correct |
109 ms |
189528 KB |
Output is correct |
133 |
Correct |
101 ms |
188172 KB |
Output is correct |
134 |
Correct |
90 ms |
188236 KB |
Output is correct |
135 |
Correct |
90 ms |
188988 KB |
Output is correct |
136 |
Correct |
98 ms |
190156 KB |
Output is correct |
137 |
Correct |
107 ms |
190068 KB |
Output is correct |
138 |
Correct |
96 ms |
190420 KB |
Output is correct |
139 |
Correct |
102 ms |
189516 KB |
Output is correct |
140 |
Correct |
101 ms |
189468 KB |
Output is correct |
141 |
Correct |
98 ms |
190468 KB |
Output is correct |
142 |
Correct |
92 ms |
189908 KB |
Output is correct |
143 |
Correct |
98 ms |
189960 KB |
Output is correct |
144 |
Correct |
98 ms |
190696 KB |
Output is correct |
145 |
Correct |
100 ms |
190768 KB |
Output is correct |
146 |
Correct |
99 ms |
190000 KB |
Output is correct |
147 |
Correct |
96 ms |
189512 KB |
Output is correct |
148 |
Correct |
94 ms |
189516 KB |
Output is correct |
149 |
Correct |
101 ms |
189472 KB |
Output is correct |
150 |
Correct |
93 ms |
189528 KB |
Output is correct |
151 |
Correct |
102 ms |
189564 KB |
Output is correct |
152 |
Correct |
92 ms |
189480 KB |
Output is correct |
153 |
Correct |
96 ms |
189540 KB |
Output is correct |
154 |
Correct |
122 ms |
191408 KB |
Output is correct |
155 |
Correct |
97 ms |
190016 KB |
Output is correct |
156 |
Correct |
111 ms |
192268 KB |
Output is correct |
157 |
Correct |
113 ms |
191288 KB |
Output is correct |
158 |
Correct |
113 ms |
193876 KB |
Output is correct |
159 |
Correct |
119 ms |
191440 KB |
Output is correct |
160 |
Correct |
114 ms |
191588 KB |
Output is correct |
161 |
Correct |
113 ms |
193868 KB |
Output is correct |
162 |
Correct |
94 ms |
192716 KB |
Output is correct |
163 |
Correct |
100 ms |
192688 KB |
Output is correct |
164 |
Correct |
111 ms |
194500 KB |
Output is correct |
165 |
Correct |
116 ms |
194456 KB |
Output is correct |
166 |
Correct |
116 ms |
192960 KB |
Output is correct |
167 |
Correct |
110 ms |
191484 KB |
Output is correct |
168 |
Correct |
114 ms |
191552 KB |
Output is correct |
169 |
Correct |
124 ms |
191572 KB |
Output is correct |
170 |
Correct |
111 ms |
191676 KB |
Output is correct |
171 |
Correct |
110 ms |
191820 KB |
Output is correct |
172 |
Correct |
124 ms |
191664 KB |
Output is correct |
173 |
Correct |
95 ms |
191448 KB |
Output is correct |
174 |
Correct |
108 ms |
192684 KB |
Output is correct |
175 |
Correct |
143 ms |
195532 KB |
Output is correct |
176 |
Correct |
140 ms |
210088 KB |
Output is correct |
177 |
Correct |
206 ms |
211104 KB |
Output is correct |
178 |
Correct |
114 ms |
217496 KB |
Output is correct |
179 |
Correct |
227 ms |
221640 KB |
Output is correct |
180 |
Correct |
329 ms |
220296 KB |
Output is correct |
181 |
Correct |
328 ms |
221236 KB |
Output is correct |
182 |
Correct |
334 ms |
221176 KB |
Output is correct |
183 |
Correct |
374 ms |
222580 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
86 ms |
188104 KB |
Output is correct |
2 |
Correct |
87 ms |
188164 KB |
Output is correct |
3 |
Correct |
88 ms |
188200 KB |
Output is correct |
4 |
Correct |
85 ms |
188108 KB |
Output is correct |
5 |
Correct |
90 ms |
188172 KB |
Output is correct |
6 |
Correct |
86 ms |
188164 KB |
Output is correct |
7 |
Correct |
85 ms |
188216 KB |
Output is correct |
8 |
Correct |
90 ms |
188192 KB |
Output is correct |
9 |
Correct |
86 ms |
188104 KB |
Output is correct |
10 |
Correct |
90 ms |
188168 KB |
Output is correct |
11 |
Correct |
86 ms |
188080 KB |
Output is correct |
12 |
Correct |
101 ms |
188044 KB |
Output is correct |
13 |
Correct |
99 ms |
188164 KB |
Output is correct |
14 |
Correct |
93 ms |
188056 KB |
Output is correct |
15 |
Correct |
91 ms |
188168 KB |
Output is correct |
16 |
Correct |
88 ms |
188140 KB |
Output is correct |
17 |
Correct |
87 ms |
188108 KB |
Output is correct |
18 |
Correct |
86 ms |
188172 KB |
Output is correct |
19 |
Correct |
102 ms |
189424 KB |
Output is correct |
20 |
Correct |
92 ms |
190136 KB |
Output is correct |
21 |
Correct |
97 ms |
190412 KB |
Output is correct |
22 |
Correct |
98 ms |
189504 KB |
Output is correct |
23 |
Correct |
101 ms |
189424 KB |
Output is correct |
24 |
Correct |
92 ms |
190688 KB |
Output is correct |
25 |
Correct |
95 ms |
190772 KB |
Output is correct |
26 |
Correct |
88 ms |
189556 KB |
Output is correct |
27 |
Correct |
88 ms |
189456 KB |
Output is correct |
28 |
Correct |
88 ms |
189428 KB |
Output is correct |
29 |
Correct |
116 ms |
191352 KB |
Output is correct |
30 |
Correct |
96 ms |
190124 KB |
Output is correct |
31 |
Correct |
111 ms |
193828 KB |
Output is correct |
32 |
Correct |
117 ms |
191524 KB |
Output is correct |
33 |
Correct |
120 ms |
191408 KB |
Output is correct |
34 |
Correct |
115 ms |
194372 KB |
Output is correct |
35 |
Correct |
117 ms |
194372 KB |
Output is correct |
36 |
Correct |
104 ms |
191640 KB |
Output is correct |
37 |
Correct |
109 ms |
191436 KB |
Output is correct |
38 |
Correct |
92 ms |
191424 KB |
Output is correct |
39 |
Correct |
429 ms |
219872 KB |
Output is correct |
40 |
Correct |
114 ms |
191940 KB |
Output is correct |
41 |
Correct |
103 ms |
195736 KB |
Output is correct |
42 |
Correct |
141 ms |
192756 KB |
Output is correct |
43 |
Correct |
115 ms |
195712 KB |
Output is correct |
44 |
Correct |
139 ms |
206176 KB |
Output is correct |
45 |
Correct |
153 ms |
208952 KB |
Output is correct |
46 |
Correct |
409 ms |
245176 KB |
Output is correct |
47 |
Correct |
407 ms |
220468 KB |
Output is correct |
48 |
Correct |
378 ms |
220872 KB |
Output is correct |
49 |
Correct |
216 ms |
249928 KB |
Output is correct |
50 |
Correct |
268 ms |
249960 KB |
Output is correct |
51 |
Correct |
332 ms |
221436 KB |
Output is correct |
52 |
Correct |
261 ms |
221092 KB |
Output is correct |
53 |
Correct |
372 ms |
220920 KB |
Output is correct |
54 |
Correct |
99 ms |
188172 KB |
Output is correct |
55 |
Correct |
90 ms |
188080 KB |
Output is correct |
56 |
Correct |
90 ms |
188208 KB |
Output is correct |
57 |
Correct |
85 ms |
188168 KB |
Output is correct |
58 |
Correct |
89 ms |
188144 KB |
Output is correct |
59 |
Correct |
88 ms |
188088 KB |
Output is correct |
60 |
Correct |
85 ms |
188220 KB |
Output is correct |
61 |
Correct |
88 ms |
188148 KB |
Output is correct |
62 |
Correct |
87 ms |
188144 KB |
Output is correct |
63 |
Correct |
88 ms |
188108 KB |
Output is correct |
64 |
Correct |
94 ms |
188104 KB |
Output is correct |
65 |
Correct |
88 ms |
188180 KB |
Output is correct |
66 |
Correct |
89 ms |
188204 KB |
Output is correct |
67 |
Correct |
87 ms |
188160 KB |
Output is correct |
68 |
Correct |
98 ms |
188200 KB |
Output is correct |
69 |
Correct |
88 ms |
188164 KB |
Output is correct |
70 |
Correct |
89 ms |
188208 KB |
Output is correct |
71 |
Correct |
91 ms |
188048 KB |
Output is correct |
72 |
Correct |
88 ms |
188108 KB |
Output is correct |
73 |
Correct |
89 ms |
188092 KB |
Output is correct |
74 |
Correct |
88 ms |
188116 KB |
Output is correct |
75 |
Correct |
90 ms |
188176 KB |
Output is correct |
76 |
Correct |
96 ms |
188108 KB |
Output is correct |
77 |
Correct |
87 ms |
188116 KB |
Output is correct |
78 |
Correct |
89 ms |
188108 KB |
Output is correct |
79 |
Correct |
90 ms |
188096 KB |
Output is correct |
80 |
Correct |
94 ms |
188128 KB |
Output is correct |
81 |
Correct |
91 ms |
188108 KB |
Output is correct |
82 |
Correct |
90 ms |
188108 KB |
Output is correct |
83 |
Correct |
92 ms |
188160 KB |
Output is correct |
84 |
Correct |
86 ms |
188104 KB |
Output is correct |
85 |
Correct |
88 ms |
188200 KB |
Output is correct |
86 |
Correct |
94 ms |
188108 KB |
Output is correct |
87 |
Correct |
99 ms |
188176 KB |
Output is correct |
88 |
Correct |
88 ms |
188136 KB |
Output is correct |
89 |
Correct |
86 ms |
188104 KB |
Output is correct |
90 |
Correct |
87 ms |
188108 KB |
Output is correct |
91 |
Correct |
95 ms |
188112 KB |
Output is correct |
92 |
Correct |
93 ms |
188168 KB |
Output is correct |
93 |
Correct |
88 ms |
188104 KB |
Output is correct |
94 |
Correct |
95 ms |
188216 KB |
Output is correct |
95 |
Correct |
93 ms |
188196 KB |
Output is correct |
96 |
Correct |
91 ms |
188252 KB |
Output is correct |
97 |
Correct |
91 ms |
188224 KB |
Output is correct |
98 |
Correct |
87 ms |
188148 KB |
Output is correct |
99 |
Correct |
95 ms |
188108 KB |
Output is correct |
100 |
Correct |
92 ms |
188084 KB |
Output is correct |
101 |
Correct |
88 ms |
188176 KB |
Output is correct |
102 |
Correct |
90 ms |
188120 KB |
Output is correct |
103 |
Correct |
88 ms |
188172 KB |
Output is correct |
104 |
Correct |
93 ms |
188144 KB |
Output is correct |
105 |
Correct |
90 ms |
188168 KB |
Output is correct |
106 |
Correct |
89 ms |
188116 KB |
Output is correct |
107 |
Correct |
92 ms |
188204 KB |
Output is correct |
108 |
Correct |
89 ms |
188176 KB |
Output is correct |
109 |
Correct |
90 ms |
188104 KB |
Output is correct |
110 |
Correct |
89 ms |
189024 KB |
Output is correct |
111 |
Correct |
97 ms |
190020 KB |
Output is correct |
112 |
Correct |
103 ms |
190396 KB |
Output is correct |
113 |
Correct |
97 ms |
190424 KB |
Output is correct |
114 |
Correct |
91 ms |
189908 KB |
Output is correct |
115 |
Correct |
92 ms |
189932 KB |
Output is correct |
116 |
Correct |
91 ms |
189472 KB |
Output is correct |
117 |
Correct |
92 ms |
189512 KB |
Output is correct |
118 |
Correct |
91 ms |
189664 KB |
Output is correct |
119 |
Correct |
108 ms |
192256 KB |
Output is correct |
120 |
Correct |
111 ms |
193868 KB |
Output is correct |
121 |
Correct |
118 ms |
193864 KB |
Output is correct |
122 |
Correct |
94 ms |
192716 KB |
Output is correct |
123 |
Correct |
94 ms |
192716 KB |
Output is correct |
124 |
Correct |
169 ms |
202764 KB |
Output is correct |
125 |
Correct |
324 ms |
230932 KB |
Output is correct |
126 |
Correct |
454 ms |
245096 KB |
Output is correct |
127 |
Correct |
340 ms |
244968 KB |
Output is correct |
128 |
Correct |
141 ms |
233160 KB |
Output is correct |
129 |
Correct |
158 ms |
233036 KB |
Output is correct |
130 |
Correct |
299 ms |
235828 KB |
Output is correct |
131 |
Correct |
319 ms |
235756 KB |
Output is correct |
132 |
Correct |
109 ms |
189528 KB |
Output is correct |
133 |
Correct |
101 ms |
188172 KB |
Output is correct |
134 |
Correct |
90 ms |
188236 KB |
Output is correct |
135 |
Correct |
90 ms |
188988 KB |
Output is correct |
136 |
Correct |
98 ms |
190156 KB |
Output is correct |
137 |
Correct |
107 ms |
190068 KB |
Output is correct |
138 |
Correct |
96 ms |
190420 KB |
Output is correct |
139 |
Correct |
102 ms |
189516 KB |
Output is correct |
140 |
Correct |
101 ms |
189468 KB |
Output is correct |
141 |
Correct |
98 ms |
190468 KB |
Output is correct |
142 |
Correct |
92 ms |
189908 KB |
Output is correct |
143 |
Correct |
98 ms |
189960 KB |
Output is correct |
144 |
Correct |
98 ms |
190696 KB |
Output is correct |
145 |
Correct |
100 ms |
190768 KB |
Output is correct |
146 |
Correct |
99 ms |
190000 KB |
Output is correct |
147 |
Correct |
96 ms |
189512 KB |
Output is correct |
148 |
Correct |
94 ms |
189516 KB |
Output is correct |
149 |
Correct |
101 ms |
189472 KB |
Output is correct |
150 |
Correct |
93 ms |
189528 KB |
Output is correct |
151 |
Correct |
102 ms |
189564 KB |
Output is correct |
152 |
Correct |
92 ms |
189480 KB |
Output is correct |
153 |
Correct |
96 ms |
189540 KB |
Output is correct |
154 |
Correct |
122 ms |
191408 KB |
Output is correct |
155 |
Correct |
97 ms |
190016 KB |
Output is correct |
156 |
Correct |
111 ms |
192268 KB |
Output is correct |
157 |
Correct |
113 ms |
191288 KB |
Output is correct |
158 |
Correct |
113 ms |
193876 KB |
Output is correct |
159 |
Correct |
119 ms |
191440 KB |
Output is correct |
160 |
Correct |
114 ms |
191588 KB |
Output is correct |
161 |
Correct |
113 ms |
193868 KB |
Output is correct |
162 |
Correct |
94 ms |
192716 KB |
Output is correct |
163 |
Correct |
100 ms |
192688 KB |
Output is correct |
164 |
Correct |
111 ms |
194500 KB |
Output is correct |
165 |
Correct |
116 ms |
194456 KB |
Output is correct |
166 |
Correct |
116 ms |
192960 KB |
Output is correct |
167 |
Correct |
110 ms |
191484 KB |
Output is correct |
168 |
Correct |
114 ms |
191552 KB |
Output is correct |
169 |
Correct |
124 ms |
191572 KB |
Output is correct |
170 |
Correct |
111 ms |
191676 KB |
Output is correct |
171 |
Correct |
110 ms |
191820 KB |
Output is correct |
172 |
Correct |
124 ms |
191664 KB |
Output is correct |
173 |
Correct |
95 ms |
191448 KB |
Output is correct |
174 |
Correct |
108 ms |
192684 KB |
Output is correct |
175 |
Correct |
143 ms |
195532 KB |
Output is correct |
176 |
Correct |
140 ms |
210088 KB |
Output is correct |
177 |
Correct |
206 ms |
211104 KB |
Output is correct |
178 |
Correct |
114 ms |
217496 KB |
Output is correct |
179 |
Correct |
227 ms |
221640 KB |
Output is correct |
180 |
Correct |
329 ms |
220296 KB |
Output is correct |
181 |
Correct |
328 ms |
221236 KB |
Output is correct |
182 |
Correct |
334 ms |
221176 KB |
Output is correct |
183 |
Correct |
374 ms |
222580 KB |
Output is correct |
184 |
Correct |
940 ms |
253320 KB |
Output is correct |
185 |
Correct |
177 ms |
225356 KB |
Output is correct |
186 |
Correct |
435 ms |
246512 KB |
Output is correct |
187 |
Correct |
154 ms |
235084 KB |
Output is correct |
188 |
Correct |
734 ms |
301616 KB |
Output is correct |
189 |
Correct |
594 ms |
253320 KB |
Output is correct |
190 |
Correct |
362 ms |
253124 KB |
Output is correct |
191 |
Correct |
605 ms |
301940 KB |
Output is correct |
192 |
Correct |
232 ms |
277472 KB |
Output is correct |
193 |
Correct |
191 ms |
277512 KB |
Output is correct |
194 |
Correct |
467 ms |
311140 KB |
Output is correct |
195 |
Correct |
477 ms |
310572 KB |
Output is correct |
196 |
Correct |
610 ms |
254776 KB |
Output is correct |
197 |
Correct |
346 ms |
254496 KB |
Output is correct |
198 |
Correct |
329 ms |
253908 KB |
Output is correct |
199 |
Correct |
613 ms |
254880 KB |
Output is correct |
200 |
Correct |
367 ms |
254164 KB |
Output is correct |
201 |
Correct |
572 ms |
253468 KB |
Output is correct |
202 |
Correct |
858 ms |
253272 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
86 ms |
188104 KB |
Output is correct |
2 |
Correct |
87 ms |
188164 KB |
Output is correct |
3 |
Correct |
88 ms |
188200 KB |
Output is correct |
4 |
Correct |
85 ms |
188108 KB |
Output is correct |
5 |
Correct |
90 ms |
188172 KB |
Output is correct |
6 |
Correct |
86 ms |
188164 KB |
Output is correct |
7 |
Correct |
85 ms |
188216 KB |
Output is correct |
8 |
Correct |
90 ms |
188192 KB |
Output is correct |
9 |
Correct |
86 ms |
188104 KB |
Output is correct |
10 |
Correct |
90 ms |
188168 KB |
Output is correct |
11 |
Correct |
86 ms |
188080 KB |
Output is correct |
12 |
Correct |
101 ms |
188044 KB |
Output is correct |
13 |
Correct |
99 ms |
188164 KB |
Output is correct |
14 |
Correct |
93 ms |
188056 KB |
Output is correct |
15 |
Correct |
91 ms |
188168 KB |
Output is correct |
16 |
Correct |
88 ms |
188140 KB |
Output is correct |
17 |
Correct |
87 ms |
188108 KB |
Output is correct |
18 |
Correct |
86 ms |
188172 KB |
Output is correct |
19 |
Correct |
102 ms |
189424 KB |
Output is correct |
20 |
Correct |
92 ms |
190136 KB |
Output is correct |
21 |
Correct |
97 ms |
190412 KB |
Output is correct |
22 |
Correct |
98 ms |
189504 KB |
Output is correct |
23 |
Correct |
101 ms |
189424 KB |
Output is correct |
24 |
Correct |
92 ms |
190688 KB |
Output is correct |
25 |
Correct |
95 ms |
190772 KB |
Output is correct |
26 |
Correct |
88 ms |
189556 KB |
Output is correct |
27 |
Correct |
88 ms |
189456 KB |
Output is correct |
28 |
Correct |
88 ms |
189428 KB |
Output is correct |
29 |
Correct |
116 ms |
191352 KB |
Output is correct |
30 |
Correct |
96 ms |
190124 KB |
Output is correct |
31 |
Correct |
111 ms |
193828 KB |
Output is correct |
32 |
Correct |
117 ms |
191524 KB |
Output is correct |
33 |
Correct |
120 ms |
191408 KB |
Output is correct |
34 |
Correct |
115 ms |
194372 KB |
Output is correct |
35 |
Correct |
117 ms |
194372 KB |
Output is correct |
36 |
Correct |
104 ms |
191640 KB |
Output is correct |
37 |
Correct |
109 ms |
191436 KB |
Output is correct |
38 |
Correct |
92 ms |
191424 KB |
Output is correct |
39 |
Correct |
429 ms |
219872 KB |
Output is correct |
40 |
Correct |
114 ms |
191940 KB |
Output is correct |
41 |
Correct |
103 ms |
195736 KB |
Output is correct |
42 |
Correct |
141 ms |
192756 KB |
Output is correct |
43 |
Correct |
115 ms |
195712 KB |
Output is correct |
44 |
Correct |
139 ms |
206176 KB |
Output is correct |
45 |
Correct |
153 ms |
208952 KB |
Output is correct |
46 |
Correct |
409 ms |
245176 KB |
Output is correct |
47 |
Correct |
407 ms |
220468 KB |
Output is correct |
48 |
Correct |
378 ms |
220872 KB |
Output is correct |
49 |
Correct |
216 ms |
249928 KB |
Output is correct |
50 |
Correct |
268 ms |
249960 KB |
Output is correct |
51 |
Correct |
332 ms |
221436 KB |
Output is correct |
52 |
Correct |
261 ms |
221092 KB |
Output is correct |
53 |
Correct |
372 ms |
220920 KB |
Output is correct |
54 |
Correct |
99 ms |
188172 KB |
Output is correct |
55 |
Correct |
90 ms |
188080 KB |
Output is correct |
56 |
Correct |
90 ms |
188208 KB |
Output is correct |
57 |
Correct |
85 ms |
188168 KB |
Output is correct |
58 |
Correct |
89 ms |
188144 KB |
Output is correct |
59 |
Correct |
88 ms |
188088 KB |
Output is correct |
60 |
Correct |
85 ms |
188220 KB |
Output is correct |
61 |
Correct |
88 ms |
188148 KB |
Output is correct |
62 |
Correct |
87 ms |
188144 KB |
Output is correct |
63 |
Correct |
88 ms |
188108 KB |
Output is correct |
64 |
Correct |
94 ms |
188104 KB |
Output is correct |
65 |
Correct |
88 ms |
188180 KB |
Output is correct |
66 |
Correct |
89 ms |
188204 KB |
Output is correct |
67 |
Correct |
87 ms |
188160 KB |
Output is correct |
68 |
Correct |
98 ms |
188200 KB |
Output is correct |
69 |
Correct |
88 ms |
188164 KB |
Output is correct |
70 |
Correct |
89 ms |
188208 KB |
Output is correct |
71 |
Correct |
91 ms |
188048 KB |
Output is correct |
72 |
Correct |
88 ms |
188108 KB |
Output is correct |
73 |
Correct |
89 ms |
188092 KB |
Output is correct |
74 |
Correct |
88 ms |
188116 KB |
Output is correct |
75 |
Correct |
90 ms |
188176 KB |
Output is correct |
76 |
Correct |
96 ms |
188108 KB |
Output is correct |
77 |
Correct |
87 ms |
188116 KB |
Output is correct |
78 |
Correct |
89 ms |
188108 KB |
Output is correct |
79 |
Correct |
90 ms |
188096 KB |
Output is correct |
80 |
Correct |
94 ms |
188128 KB |
Output is correct |
81 |
Correct |
91 ms |
188108 KB |
Output is correct |
82 |
Correct |
90 ms |
188108 KB |
Output is correct |
83 |
Correct |
92 ms |
188160 KB |
Output is correct |
84 |
Correct |
86 ms |
188104 KB |
Output is correct |
85 |
Correct |
88 ms |
188200 KB |
Output is correct |
86 |
Correct |
94 ms |
188108 KB |
Output is correct |
87 |
Correct |
99 ms |
188176 KB |
Output is correct |
88 |
Correct |
88 ms |
188136 KB |
Output is correct |
89 |
Correct |
86 ms |
188104 KB |
Output is correct |
90 |
Correct |
87 ms |
188108 KB |
Output is correct |
91 |
Correct |
95 ms |
188112 KB |
Output is correct |
92 |
Correct |
93 ms |
188168 KB |
Output is correct |
93 |
Correct |
88 ms |
188104 KB |
Output is correct |
94 |
Correct |
95 ms |
188216 KB |
Output is correct |
95 |
Correct |
93 ms |
188196 KB |
Output is correct |
96 |
Correct |
91 ms |
188252 KB |
Output is correct |
97 |
Correct |
91 ms |
188224 KB |
Output is correct |
98 |
Correct |
87 ms |
188148 KB |
Output is correct |
99 |
Correct |
95 ms |
188108 KB |
Output is correct |
100 |
Correct |
92 ms |
188084 KB |
Output is correct |
101 |
Correct |
88 ms |
188176 KB |
Output is correct |
102 |
Correct |
90 ms |
188120 KB |
Output is correct |
103 |
Correct |
88 ms |
188172 KB |
Output is correct |
104 |
Correct |
93 ms |
188144 KB |
Output is correct |
105 |
Correct |
90 ms |
188168 KB |
Output is correct |
106 |
Correct |
89 ms |
188116 KB |
Output is correct |
107 |
Correct |
92 ms |
188204 KB |
Output is correct |
108 |
Correct |
89 ms |
188176 KB |
Output is correct |
109 |
Correct |
90 ms |
188104 KB |
Output is correct |
110 |
Correct |
89 ms |
189024 KB |
Output is correct |
111 |
Correct |
97 ms |
190020 KB |
Output is correct |
112 |
Correct |
103 ms |
190396 KB |
Output is correct |
113 |
Correct |
97 ms |
190424 KB |
Output is correct |
114 |
Correct |
91 ms |
189908 KB |
Output is correct |
115 |
Correct |
92 ms |
189932 KB |
Output is correct |
116 |
Correct |
91 ms |
189472 KB |
Output is correct |
117 |
Correct |
92 ms |
189512 KB |
Output is correct |
118 |
Correct |
91 ms |
189664 KB |
Output is correct |
119 |
Correct |
108 ms |
192256 KB |
Output is correct |
120 |
Correct |
111 ms |
193868 KB |
Output is correct |
121 |
Correct |
118 ms |
193864 KB |
Output is correct |
122 |
Correct |
94 ms |
192716 KB |
Output is correct |
123 |
Correct |
94 ms |
192716 KB |
Output is correct |
124 |
Correct |
169 ms |
202764 KB |
Output is correct |
125 |
Correct |
324 ms |
230932 KB |
Output is correct |
126 |
Correct |
454 ms |
245096 KB |
Output is correct |
127 |
Correct |
340 ms |
244968 KB |
Output is correct |
128 |
Correct |
141 ms |
233160 KB |
Output is correct |
129 |
Correct |
158 ms |
233036 KB |
Output is correct |
130 |
Correct |
299 ms |
235828 KB |
Output is correct |
131 |
Correct |
319 ms |
235756 KB |
Output is correct |
132 |
Correct |
109 ms |
189528 KB |
Output is correct |
133 |
Correct |
101 ms |
188172 KB |
Output is correct |
134 |
Correct |
90 ms |
188236 KB |
Output is correct |
135 |
Correct |
90 ms |
188988 KB |
Output is correct |
136 |
Correct |
98 ms |
190156 KB |
Output is correct |
137 |
Correct |
107 ms |
190068 KB |
Output is correct |
138 |
Correct |
96 ms |
190420 KB |
Output is correct |
139 |
Correct |
102 ms |
189516 KB |
Output is correct |
140 |
Correct |
101 ms |
189468 KB |
Output is correct |
141 |
Correct |
98 ms |
190468 KB |
Output is correct |
142 |
Correct |
92 ms |
189908 KB |
Output is correct |
143 |
Correct |
98 ms |
189960 KB |
Output is correct |
144 |
Correct |
98 ms |
190696 KB |
Output is correct |
145 |
Correct |
100 ms |
190768 KB |
Output is correct |
146 |
Correct |
99 ms |
190000 KB |
Output is correct |
147 |
Correct |
96 ms |
189512 KB |
Output is correct |
148 |
Correct |
94 ms |
189516 KB |
Output is correct |
149 |
Correct |
101 ms |
189472 KB |
Output is correct |
150 |
Correct |
93 ms |
189528 KB |
Output is correct |
151 |
Correct |
102 ms |
189564 KB |
Output is correct |
152 |
Correct |
92 ms |
189480 KB |
Output is correct |
153 |
Correct |
96 ms |
189540 KB |
Output is correct |
154 |
Correct |
122 ms |
191408 KB |
Output is correct |
155 |
Correct |
97 ms |
190016 KB |
Output is correct |
156 |
Correct |
111 ms |
192268 KB |
Output is correct |
157 |
Correct |
113 ms |
191288 KB |
Output is correct |
158 |
Correct |
113 ms |
193876 KB |
Output is correct |
159 |
Correct |
119 ms |
191440 KB |
Output is correct |
160 |
Correct |
114 ms |
191588 KB |
Output is correct |
161 |
Correct |
113 ms |
193868 KB |
Output is correct |
162 |
Correct |
94 ms |
192716 KB |
Output is correct |
163 |
Correct |
100 ms |
192688 KB |
Output is correct |
164 |
Correct |
111 ms |
194500 KB |
Output is correct |
165 |
Correct |
116 ms |
194456 KB |
Output is correct |
166 |
Correct |
116 ms |
192960 KB |
Output is correct |
167 |
Correct |
110 ms |
191484 KB |
Output is correct |
168 |
Correct |
114 ms |
191552 KB |
Output is correct |
169 |
Correct |
124 ms |
191572 KB |
Output is correct |
170 |
Correct |
111 ms |
191676 KB |
Output is correct |
171 |
Correct |
110 ms |
191820 KB |
Output is correct |
172 |
Correct |
124 ms |
191664 KB |
Output is correct |
173 |
Correct |
95 ms |
191448 KB |
Output is correct |
174 |
Correct |
108 ms |
192684 KB |
Output is correct |
175 |
Correct |
143 ms |
195532 KB |
Output is correct |
176 |
Correct |
140 ms |
210088 KB |
Output is correct |
177 |
Correct |
206 ms |
211104 KB |
Output is correct |
178 |
Correct |
114 ms |
217496 KB |
Output is correct |
179 |
Correct |
227 ms |
221640 KB |
Output is correct |
180 |
Correct |
329 ms |
220296 KB |
Output is correct |
181 |
Correct |
328 ms |
221236 KB |
Output is correct |
182 |
Correct |
334 ms |
221176 KB |
Output is correct |
183 |
Correct |
374 ms |
222580 KB |
Output is correct |
184 |
Correct |
940 ms |
253320 KB |
Output is correct |
185 |
Correct |
177 ms |
225356 KB |
Output is correct |
186 |
Correct |
435 ms |
246512 KB |
Output is correct |
187 |
Correct |
154 ms |
235084 KB |
Output is correct |
188 |
Correct |
734 ms |
301616 KB |
Output is correct |
189 |
Correct |
594 ms |
253320 KB |
Output is correct |
190 |
Correct |
362 ms |
253124 KB |
Output is correct |
191 |
Correct |
605 ms |
301940 KB |
Output is correct |
192 |
Correct |
232 ms |
277472 KB |
Output is correct |
193 |
Correct |
191 ms |
277512 KB |
Output is correct |
194 |
Correct |
467 ms |
311140 KB |
Output is correct |
195 |
Correct |
477 ms |
310572 KB |
Output is correct |
196 |
Correct |
610 ms |
254776 KB |
Output is correct |
197 |
Correct |
346 ms |
254496 KB |
Output is correct |
198 |
Correct |
329 ms |
253908 KB |
Output is correct |
199 |
Correct |
613 ms |
254880 KB |
Output is correct |
200 |
Correct |
367 ms |
254164 KB |
Output is correct |
201 |
Correct |
572 ms |
253468 KB |
Output is correct |
202 |
Correct |
858 ms |
253272 KB |
Output is correct |
203 |
Correct |
1583 ms |
316096 KB |
Output is correct |
204 |
Correct |
534 ms |
260856 KB |
Output is correct |
205 |
Correct |
743 ms |
267596 KB |
Output is correct |
206 |
Correct |
378 ms |
320384 KB |
Output is correct |
207 |
Correct |
1665 ms |
414484 KB |
Output is correct |
208 |
Correct |
1169 ms |
313384 KB |
Output is correct |
209 |
Correct |
1494 ms |
317840 KB |
Output is correct |
210 |
Correct |
1227 ms |
415476 KB |
Output is correct |
211 |
Correct |
308 ms |
361840 KB |
Output is correct |
212 |
Correct |
313 ms |
365156 KB |
Output is correct |
213 |
Correct |
607 ms |
433476 KB |
Output is correct |
214 |
Correct |
1018 ms |
434868 KB |
Output is correct |
215 |
Correct |
995 ms |
319004 KB |
Output is correct |
216 |
Correct |
974 ms |
320480 KB |
Output is correct |
217 |
Correct |
988 ms |
316216 KB |
Output is correct |
218 |
Correct |
811 ms |
317388 KB |
Output is correct |
219 |
Correct |
924 ms |
340092 KB |
Output is correct |
220 |
Correct |
718 ms |
357592 KB |
Output is correct |
221 |
Correct |
1139 ms |
379736 KB |
Output is correct |
222 |
Correct |
1200 ms |
376988 KB |
Output is correct |
223 |
Correct |
1167 ms |
318732 KB |
Output is correct |
224 |
Correct |
1228 ms |
313932 KB |
Output is correct |
225 |
Correct |
904 ms |
316724 KB |
Output is correct |