#include <bits/stdc++.h>
#define speed ios_base::sync_with_stdio(0); cin.tie(0)
#define all(x) (x).begin(),(x).end()
using namespace std;
typedef long long ll;
typedef long double ldb;
typedef pair<int,int> pii;
typedef pair<ll,ll> pll;
const ll MAX=5e5+10,P=1e9+7;
const ll INF=0x3f3f3f3f,oo=0x3f3f3f3f3f3f3f3f;
const int dir[4][2]={{0,1},{1,0},{-1,0},{0,-1}};
int r,c,n;
pii s,g;
vector<vector<bool> > mp,vis;
vector<set<int> > rw,col;
vector<vector<int> > dis;
bool in(int x,int y) {
return x>=0 and x<r and y>=0 and y<c;
}
bool inrg(int vx,int vy,int tgx,int tgy) {
int dx=abs(tgx-vx);
int dy=abs(tgy-vy);
if (max(dx,dy)<=n and !(dx==n and dy==n)) return true;
return false;
}
int main() {
speed;
cin>>r>>c>>n;
cin>>s.first>>s.second;
s.first--;s.second--;
cin>>g.first>>g.second;
g.first--;g.second--;
mp.resize(r,vector<bool>(c));
dis.resize(r,vector<int>(c,INF));
vis.resize(r,vector<bool>(c,0));
for (int i=0;i<r;i++) {
for (int j=0;j<c;j++) {
char c;
cin>>c;
if (c=='.') mp[i][j]=0;
else mp[i][j]=1;
}
}
rw.resize(r);
col.resize(c);
for (int i=0;i<r;i++) {
for (int j=0;j<c;j++) {
rw[i].insert(j);
col[j].insert(i);
}
}
deque<pii> DBFS;
dis[s.first][s.second]=0;
DBFS.push_front(s);
while (!DBFS.empty()) {
auto [vx,vy]=DBFS.front();
// cout<<vx<<" "<<vy<<" v\n"<<flush;
DBFS.pop_front();
for (int k=0;k<4;k++) {
int nx=vx+dir[k][0];
int ny=vy+dir[k][1];
// cout<<nx<<" "<<ny<<" n\n";
// if (in(nx,ny)) cout<<dis[nx][ny]<<" "<<dis[vx][vy]<<" "<<mp[nx][ny]<<"\n";
if (in(nx,ny) and !mp[nx][ny] and dis[nx][ny]>dis[vx][vy]) {
DBFS.push_front({nx,ny});
dis[nx][ny]=dis[vx][vy];
rw[nx].erase(ny);
col[ny].erase(nx);
}
}
if (inrg(vx,vy,g.first,g.second)) {
if (dis[g.first][g.second]>dis[vx][vy]+1) {
dis[g.first][g.second]=dis[vx][vy]+1;
DBFS.push_back(g);
}
continue;
}
if (vx-n>=0) {
int nx=vx-n;
auto it=rw[nx].upper_bound(max(0,vy-n+1)-1);
while (it!=rw[nx].end() and *it<min(c,vy+n)) { // up
// cout<<nx<<" "<<ny<<" nU\n";
if (dis[nx][*it]>dis[vx][vy]+1) {
DBFS.push_back({nx,*it});
dis[nx][*it]=dis[vx][vy]+1;
}
col[*it].erase(nx);
it=rw[nx].erase(it);
}
}
if (vx+n<r) {
int nx=vx+n;
auto it=rw[nx].upper_bound(max(0,vy-n+1)-1);
while (it!=rw[nx].end() and *it<min(c,vy+n)) { // down
// cout<<nx<<" "<<ny<<" nD\n";
if (dis[nx][*it]>dis[vx][vy]+1) {
DBFS.push_back({nx,*it});
dis[nx][*it]=dis[vx][vy]+1;
}
col[*it].erase(nx);
it=rw[nx].erase(it);
}
}
if (vy+n<c) {
int ny=vy+n;
auto it=col[ny].upper_bound(max(0,vx-n+1)-1);
while (it!=col[ny].end() and *it<min(r,vx+n)) { // right
// cout<<nx<<" "<<ny<<" nR\n";
if (dis[*it][ny]>dis[vx][vy]+1) {
DBFS.push_back({*it,ny});
dis[*it][ny]=dis[vx][vy]+1;
}
rw[*it].erase(ny);
it=col[ny].erase(it);
}
}
if (vy-n>=0) {
int ny=vy-n;
auto it=col[ny].upper_bound(max(0,vx-n+1)-1);
while (it!=col[ny].end() and *it<min(r,vx+n)) { // left
// cout<<nx<<" "<<ny<<" nL\n";
if (dis[*it][ny]>dis[vx][vy]+1) {
DBFS.push_back({*it,ny});
dis[*it][ny]=dis[vx][vy]+1;
}
rw[*it].erase(ny);
it=col[ny].erase(it);
}
}
}
// for (int i=0;i<r;i++) {
// for (int j=0;j<c;j++) cout<<dis[i][j]<<" ";
// cout<<"\n";
// }
cout<<dis[g.first][g.second]<<"\n";
return 0;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
1 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
600 KB |
Output is correct |
6 |
Correct |
1 ms |
348 KB |
Output is correct |
7 |
Correct |
1 ms |
348 KB |
Output is correct |
8 |
Correct |
1 ms |
348 KB |
Output is correct |
9 |
Correct |
0 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
0 ms |
348 KB |
Output is correct |
12 |
Correct |
0 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
1 ms |
344 KB |
Output is correct |
15 |
Correct |
0 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
1 ms |
348 KB |
Output is correct |
19 |
Correct |
25 ms |
6236 KB |
Output is correct |
20 |
Correct |
14 ms |
7076 KB |
Output is correct |
21 |
Correct |
20 ms |
6236 KB |
Output is correct |
22 |
Correct |
28 ms |
6236 KB |
Output is correct |
23 |
Correct |
21 ms |
6236 KB |
Output is correct |
24 |
Correct |
18 ms |
9072 KB |
Output is correct |
25 |
Correct |
17 ms |
9072 KB |
Output is correct |
26 |
Correct |
28 ms |
6236 KB |
Output is correct |
27 |
Correct |
27 ms |
6236 KB |
Output is correct |
28 |
Correct |
21 ms |
6332 KB |
Output is correct |
29 |
Correct |
64 ms |
15196 KB |
Output is correct |
30 |
Correct |
23 ms |
7768 KB |
Output is correct |
31 |
Correct |
56 ms |
15196 KB |
Output is correct |
32 |
Correct |
75 ms |
15232 KB |
Output is correct |
33 |
Correct |
70 ms |
15116 KB |
Output is correct |
34 |
Correct |
58 ms |
22236 KB |
Output is correct |
35 |
Correct |
52 ms |
21980 KB |
Output is correct |
36 |
Correct |
76 ms |
15196 KB |
Output is correct |
37 |
Correct |
79 ms |
15444 KB |
Output is correct |
38 |
Correct |
64 ms |
14996 KB |
Output is correct |
39 |
Correct |
834 ms |
147624 KB |
Output is correct |
40 |
Correct |
81 ms |
17580 KB |
Output is correct |
41 |
Correct |
77 ms |
27008 KB |
Output is correct |
42 |
Correct |
103 ms |
21340 KB |
Output is correct |
43 |
Correct |
87 ms |
29700 KB |
Output is correct |
44 |
Correct |
426 ms |
79092 KB |
Output is correct |
45 |
Correct |
408 ms |
86496 KB |
Output is correct |
46 |
Correct |
685 ms |
147796 KB |
Output is correct |
47 |
Correct |
890 ms |
147824 KB |
Output is correct |
48 |
Correct |
945 ms |
147828 KB |
Output is correct |
49 |
Correct |
586 ms |
218036 KB |
Output is correct |
50 |
Correct |
555 ms |
217928 KB |
Output is correct |
51 |
Correct |
974 ms |
147844 KB |
Output is correct |
52 |
Correct |
934 ms |
147848 KB |
Output is correct |
53 |
Correct |
892 ms |
147952 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
0 ms |
348 KB |
Output is correct |
4 |
Correct |
0 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
348 KB |
Output is correct |
6 |
Correct |
0 ms |
348 KB |
Output is correct |
7 |
Correct |
0 ms |
348 KB |
Output is correct |
8 |
Correct |
0 ms |
348 KB |
Output is correct |
9 |
Correct |
1 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
1 ms |
348 KB |
Output is correct |
12 |
Correct |
1 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
0 ms |
348 KB |
Output is correct |
15 |
Correct |
1 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
0 ms |
348 KB |
Output is correct |
19 |
Correct |
1 ms |
344 KB |
Output is correct |
20 |
Correct |
1 ms |
348 KB |
Output is correct |
21 |
Correct |
0 ms |
348 KB |
Output is correct |
22 |
Correct |
1 ms |
348 KB |
Output is correct |
23 |
Correct |
0 ms |
348 KB |
Output is correct |
24 |
Correct |
1 ms |
344 KB |
Output is correct |
25 |
Correct |
0 ms |
348 KB |
Output is correct |
26 |
Correct |
1 ms |
348 KB |
Output is correct |
27 |
Correct |
0 ms |
348 KB |
Output is correct |
28 |
Correct |
1 ms |
348 KB |
Output is correct |
29 |
Correct |
0 ms |
348 KB |
Output is correct |
30 |
Correct |
1 ms |
348 KB |
Output is correct |
31 |
Correct |
1 ms |
348 KB |
Output is correct |
32 |
Correct |
1 ms |
348 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
344 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
0 ms |
348 KB |
Output is correct |
5 |
Correct |
0 ms |
348 KB |
Output is correct |
6 |
Correct |
0 ms |
348 KB |
Output is correct |
7 |
Correct |
1 ms |
348 KB |
Output is correct |
8 |
Correct |
1 ms |
348 KB |
Output is correct |
9 |
Correct |
1 ms |
348 KB |
Output is correct |
10 |
Correct |
0 ms |
348 KB |
Output is correct |
11 |
Correct |
1 ms |
348 KB |
Output is correct |
12 |
Correct |
0 ms |
604 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
1 ms |
348 KB |
Output is correct |
15 |
Correct |
0 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
0 ms |
348 KB |
Output is correct |
18 |
Correct |
0 ms |
348 KB |
Output is correct |
19 |
Correct |
0 ms |
348 KB |
Output is correct |
20 |
Correct |
0 ms |
348 KB |
Output is correct |
21 |
Correct |
1 ms |
348 KB |
Output is correct |
22 |
Correct |
1 ms |
348 KB |
Output is correct |
23 |
Correct |
1 ms |
348 KB |
Output is correct |
24 |
Correct |
1 ms |
604 KB |
Output is correct |
25 |
Correct |
15 ms |
4228 KB |
Output is correct |
26 |
Correct |
21 ms |
5724 KB |
Output is correct |
27 |
Correct |
20 ms |
6236 KB |
Output is correct |
28 |
Correct |
23 ms |
6492 KB |
Output is correct |
29 |
Correct |
13 ms |
6236 KB |
Output is correct |
30 |
Correct |
12 ms |
6236 KB |
Output is correct |
31 |
Correct |
15 ms |
6236 KB |
Output is correct |
32 |
Correct |
28 ms |
6236 KB |
Output is correct |
33 |
Correct |
27 ms |
6376 KB |
Output is correct |
34 |
Correct |
46 ms |
12124 KB |
Output is correct |
35 |
Correct |
56 ms |
15192 KB |
Output is correct |
36 |
Correct |
58 ms |
15700 KB |
Output is correct |
37 |
Correct |
42 ms |
15176 KB |
Output is correct |
38 |
Correct |
36 ms |
15196 KB |
Output is correct |
39 |
Correct |
192 ms |
43088 KB |
Output is correct |
40 |
Correct |
695 ms |
125492 KB |
Output is correct |
41 |
Correct |
694 ms |
147848 KB |
Output is correct |
42 |
Correct |
725 ms |
148056 KB |
Output is correct |
43 |
Correct |
533 ms |
147796 KB |
Output is correct |
44 |
Correct |
521 ms |
147792 KB |
Output is correct |
45 |
Correct |
792 ms |
148568 KB |
Output is correct |
46 |
Correct |
760 ms |
148052 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
0 ms |
348 KB |
Output is correct |
4 |
Correct |
0 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
348 KB |
Output is correct |
6 |
Correct |
0 ms |
348 KB |
Output is correct |
7 |
Correct |
0 ms |
348 KB |
Output is correct |
8 |
Correct |
0 ms |
348 KB |
Output is correct |
9 |
Correct |
1 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
1 ms |
348 KB |
Output is correct |
12 |
Correct |
1 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
0 ms |
348 KB |
Output is correct |
15 |
Correct |
1 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
0 ms |
348 KB |
Output is correct |
19 |
Correct |
1 ms |
344 KB |
Output is correct |
20 |
Correct |
1 ms |
348 KB |
Output is correct |
21 |
Correct |
0 ms |
348 KB |
Output is correct |
22 |
Correct |
1 ms |
348 KB |
Output is correct |
23 |
Correct |
0 ms |
348 KB |
Output is correct |
24 |
Correct |
1 ms |
344 KB |
Output is correct |
25 |
Correct |
0 ms |
348 KB |
Output is correct |
26 |
Correct |
1 ms |
348 KB |
Output is correct |
27 |
Correct |
0 ms |
348 KB |
Output is correct |
28 |
Correct |
1 ms |
348 KB |
Output is correct |
29 |
Correct |
0 ms |
348 KB |
Output is correct |
30 |
Correct |
1 ms |
348 KB |
Output is correct |
31 |
Correct |
1 ms |
348 KB |
Output is correct |
32 |
Correct |
1 ms |
348 KB |
Output is correct |
33 |
Correct |
24 ms |
6232 KB |
Output is correct |
34 |
Correct |
1 ms |
600 KB |
Output is correct |
35 |
Correct |
1 ms |
860 KB |
Output is correct |
36 |
Correct |
15 ms |
4188 KB |
Output is correct |
37 |
Correct |
14 ms |
7076 KB |
Output is correct |
38 |
Correct |
21 ms |
5724 KB |
Output is correct |
39 |
Correct |
24 ms |
6564 KB |
Output is correct |
40 |
Correct |
31 ms |
6232 KB |
Output is correct |
41 |
Correct |
21 ms |
6232 KB |
Output is correct |
42 |
Correct |
20 ms |
6236 KB |
Output is correct |
43 |
Correct |
16 ms |
6236 KB |
Output is correct |
44 |
Correct |
12 ms |
6380 KB |
Output is correct |
45 |
Correct |
18 ms |
9068 KB |
Output is correct |
46 |
Correct |
17 ms |
9068 KB |
Output is correct |
47 |
Correct |
18 ms |
7516 KB |
Output is correct |
48 |
Correct |
18 ms |
6492 KB |
Output is correct |
49 |
Correct |
18 ms |
6236 KB |
Output is correct |
50 |
Correct |
18 ms |
6436 KB |
Output is correct |
51 |
Correct |
15 ms |
6236 KB |
Output is correct |
52 |
Correct |
38 ms |
6400 KB |
Output is correct |
53 |
Correct |
28 ms |
6236 KB |
Output is correct |
54 |
Correct |
23 ms |
6236 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
0 ms |
348 KB |
Output is correct |
4 |
Correct |
0 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
348 KB |
Output is correct |
6 |
Correct |
0 ms |
348 KB |
Output is correct |
7 |
Correct |
0 ms |
348 KB |
Output is correct |
8 |
Correct |
0 ms |
348 KB |
Output is correct |
9 |
Correct |
1 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
1 ms |
348 KB |
Output is correct |
12 |
Correct |
1 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
0 ms |
348 KB |
Output is correct |
15 |
Correct |
1 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
0 ms |
348 KB |
Output is correct |
19 |
Correct |
1 ms |
344 KB |
Output is correct |
20 |
Correct |
1 ms |
348 KB |
Output is correct |
21 |
Correct |
0 ms |
348 KB |
Output is correct |
22 |
Correct |
1 ms |
348 KB |
Output is correct |
23 |
Correct |
0 ms |
348 KB |
Output is correct |
24 |
Correct |
1 ms |
344 KB |
Output is correct |
25 |
Correct |
0 ms |
348 KB |
Output is correct |
26 |
Correct |
1 ms |
348 KB |
Output is correct |
27 |
Correct |
0 ms |
348 KB |
Output is correct |
28 |
Correct |
1 ms |
348 KB |
Output is correct |
29 |
Correct |
0 ms |
348 KB |
Output is correct |
30 |
Correct |
1 ms |
348 KB |
Output is correct |
31 |
Correct |
1 ms |
348 KB |
Output is correct |
32 |
Correct |
1 ms |
348 KB |
Output is correct |
33 |
Correct |
24 ms |
6232 KB |
Output is correct |
34 |
Correct |
1 ms |
600 KB |
Output is correct |
35 |
Correct |
1 ms |
860 KB |
Output is correct |
36 |
Correct |
15 ms |
4188 KB |
Output is correct |
37 |
Correct |
14 ms |
7076 KB |
Output is correct |
38 |
Correct |
21 ms |
5724 KB |
Output is correct |
39 |
Correct |
24 ms |
6564 KB |
Output is correct |
40 |
Correct |
31 ms |
6232 KB |
Output is correct |
41 |
Correct |
21 ms |
6232 KB |
Output is correct |
42 |
Correct |
20 ms |
6236 KB |
Output is correct |
43 |
Correct |
16 ms |
6236 KB |
Output is correct |
44 |
Correct |
12 ms |
6380 KB |
Output is correct |
45 |
Correct |
18 ms |
9068 KB |
Output is correct |
46 |
Correct |
17 ms |
9068 KB |
Output is correct |
47 |
Correct |
18 ms |
7516 KB |
Output is correct |
48 |
Correct |
18 ms |
6492 KB |
Output is correct |
49 |
Correct |
18 ms |
6236 KB |
Output is correct |
50 |
Correct |
18 ms |
6436 KB |
Output is correct |
51 |
Correct |
15 ms |
6236 KB |
Output is correct |
52 |
Correct |
38 ms |
6400 KB |
Output is correct |
53 |
Correct |
28 ms |
6236 KB |
Output is correct |
54 |
Correct |
23 ms |
6236 KB |
Output is correct |
55 |
Correct |
65 ms |
15224 KB |
Output is correct |
56 |
Correct |
23 ms |
7768 KB |
Output is correct |
57 |
Correct |
47 ms |
12300 KB |
Output is correct |
58 |
Correct |
60 ms |
14168 KB |
Output is correct |
59 |
Correct |
59 ms |
15180 KB |
Output is correct |
60 |
Correct |
77 ms |
15196 KB |
Output is correct |
61 |
Correct |
66 ms |
15144 KB |
Output is correct |
62 |
Correct |
65 ms |
15444 KB |
Output is correct |
63 |
Correct |
39 ms |
15184 KB |
Output is correct |
64 |
Correct |
40 ms |
15192 KB |
Output is correct |
65 |
Correct |
51 ms |
22032 KB |
Output is correct |
66 |
Correct |
52 ms |
21948 KB |
Output is correct |
67 |
Correct |
55 ms |
18480 KB |
Output is correct |
68 |
Correct |
50 ms |
15440 KB |
Output is correct |
69 |
Correct |
52 ms |
15184 KB |
Output is correct |
70 |
Correct |
61 ms |
15196 KB |
Output is correct |
71 |
Correct |
63 ms |
15188 KB |
Output is correct |
72 |
Correct |
77 ms |
15196 KB |
Output is correct |
73 |
Correct |
77 ms |
15188 KB |
Output is correct |
74 |
Correct |
63 ms |
15192 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
1 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
600 KB |
Output is correct |
6 |
Correct |
1 ms |
348 KB |
Output is correct |
7 |
Correct |
1 ms |
348 KB |
Output is correct |
8 |
Correct |
1 ms |
348 KB |
Output is correct |
9 |
Correct |
0 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
0 ms |
348 KB |
Output is correct |
12 |
Correct |
0 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
1 ms |
344 KB |
Output is correct |
15 |
Correct |
0 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
1 ms |
348 KB |
Output is correct |
19 |
Correct |
25 ms |
6236 KB |
Output is correct |
20 |
Correct |
14 ms |
7076 KB |
Output is correct |
21 |
Correct |
20 ms |
6236 KB |
Output is correct |
22 |
Correct |
28 ms |
6236 KB |
Output is correct |
23 |
Correct |
21 ms |
6236 KB |
Output is correct |
24 |
Correct |
18 ms |
9072 KB |
Output is correct |
25 |
Correct |
17 ms |
9072 KB |
Output is correct |
26 |
Correct |
28 ms |
6236 KB |
Output is correct |
27 |
Correct |
27 ms |
6236 KB |
Output is correct |
28 |
Correct |
21 ms |
6332 KB |
Output is correct |
29 |
Correct |
64 ms |
15196 KB |
Output is correct |
30 |
Correct |
23 ms |
7768 KB |
Output is correct |
31 |
Correct |
56 ms |
15196 KB |
Output is correct |
32 |
Correct |
75 ms |
15232 KB |
Output is correct |
33 |
Correct |
70 ms |
15116 KB |
Output is correct |
34 |
Correct |
58 ms |
22236 KB |
Output is correct |
35 |
Correct |
52 ms |
21980 KB |
Output is correct |
36 |
Correct |
76 ms |
15196 KB |
Output is correct |
37 |
Correct |
79 ms |
15444 KB |
Output is correct |
38 |
Correct |
64 ms |
14996 KB |
Output is correct |
39 |
Correct |
834 ms |
147624 KB |
Output is correct |
40 |
Correct |
81 ms |
17580 KB |
Output is correct |
41 |
Correct |
77 ms |
27008 KB |
Output is correct |
42 |
Correct |
103 ms |
21340 KB |
Output is correct |
43 |
Correct |
87 ms |
29700 KB |
Output is correct |
44 |
Correct |
426 ms |
79092 KB |
Output is correct |
45 |
Correct |
408 ms |
86496 KB |
Output is correct |
46 |
Correct |
685 ms |
147796 KB |
Output is correct |
47 |
Correct |
890 ms |
147824 KB |
Output is correct |
48 |
Correct |
945 ms |
147828 KB |
Output is correct |
49 |
Correct |
586 ms |
218036 KB |
Output is correct |
50 |
Correct |
555 ms |
217928 KB |
Output is correct |
51 |
Correct |
974 ms |
147844 KB |
Output is correct |
52 |
Correct |
934 ms |
147848 KB |
Output is correct |
53 |
Correct |
892 ms |
147952 KB |
Output is correct |
54 |
Correct |
0 ms |
348 KB |
Output is correct |
55 |
Correct |
0 ms |
348 KB |
Output is correct |
56 |
Correct |
0 ms |
348 KB |
Output is correct |
57 |
Correct |
0 ms |
348 KB |
Output is correct |
58 |
Correct |
1 ms |
348 KB |
Output is correct |
59 |
Correct |
0 ms |
348 KB |
Output is correct |
60 |
Correct |
0 ms |
348 KB |
Output is correct |
61 |
Correct |
0 ms |
348 KB |
Output is correct |
62 |
Correct |
1 ms |
348 KB |
Output is correct |
63 |
Correct |
1 ms |
348 KB |
Output is correct |
64 |
Correct |
1 ms |
348 KB |
Output is correct |
65 |
Correct |
1 ms |
348 KB |
Output is correct |
66 |
Correct |
0 ms |
348 KB |
Output is correct |
67 |
Correct |
0 ms |
348 KB |
Output is correct |
68 |
Correct |
1 ms |
348 KB |
Output is correct |
69 |
Correct |
1 ms |
348 KB |
Output is correct |
70 |
Correct |
1 ms |
348 KB |
Output is correct |
71 |
Correct |
0 ms |
348 KB |
Output is correct |
72 |
Correct |
1 ms |
344 KB |
Output is correct |
73 |
Correct |
1 ms |
348 KB |
Output is correct |
74 |
Correct |
0 ms |
348 KB |
Output is correct |
75 |
Correct |
1 ms |
348 KB |
Output is correct |
76 |
Correct |
0 ms |
348 KB |
Output is correct |
77 |
Correct |
1 ms |
344 KB |
Output is correct |
78 |
Correct |
0 ms |
348 KB |
Output is correct |
79 |
Correct |
1 ms |
348 KB |
Output is correct |
80 |
Correct |
0 ms |
348 KB |
Output is correct |
81 |
Correct |
1 ms |
348 KB |
Output is correct |
82 |
Correct |
0 ms |
348 KB |
Output is correct |
83 |
Correct |
1 ms |
348 KB |
Output is correct |
84 |
Correct |
1 ms |
348 KB |
Output is correct |
85 |
Correct |
1 ms |
348 KB |
Output is correct |
86 |
Correct |
0 ms |
348 KB |
Output is correct |
87 |
Correct |
0 ms |
344 KB |
Output is correct |
88 |
Correct |
1 ms |
348 KB |
Output is correct |
89 |
Correct |
0 ms |
348 KB |
Output is correct |
90 |
Correct |
0 ms |
348 KB |
Output is correct |
91 |
Correct |
0 ms |
348 KB |
Output is correct |
92 |
Correct |
1 ms |
348 KB |
Output is correct |
93 |
Correct |
1 ms |
348 KB |
Output is correct |
94 |
Correct |
1 ms |
348 KB |
Output is correct |
95 |
Correct |
0 ms |
348 KB |
Output is correct |
96 |
Correct |
1 ms |
348 KB |
Output is correct |
97 |
Correct |
0 ms |
604 KB |
Output is correct |
98 |
Correct |
0 ms |
348 KB |
Output is correct |
99 |
Correct |
1 ms |
348 KB |
Output is correct |
100 |
Correct |
0 ms |
348 KB |
Output is correct |
101 |
Correct |
1 ms |
348 KB |
Output is correct |
102 |
Correct |
0 ms |
348 KB |
Output is correct |
103 |
Correct |
0 ms |
348 KB |
Output is correct |
104 |
Correct |
0 ms |
348 KB |
Output is correct |
105 |
Correct |
0 ms |
348 KB |
Output is correct |
106 |
Correct |
1 ms |
348 KB |
Output is correct |
107 |
Correct |
1 ms |
348 KB |
Output is correct |
108 |
Correct |
1 ms |
348 KB |
Output is correct |
109 |
Correct |
1 ms |
604 KB |
Output is correct |
110 |
Correct |
15 ms |
4228 KB |
Output is correct |
111 |
Correct |
21 ms |
5724 KB |
Output is correct |
112 |
Correct |
20 ms |
6236 KB |
Output is correct |
113 |
Correct |
23 ms |
6492 KB |
Output is correct |
114 |
Correct |
13 ms |
6236 KB |
Output is correct |
115 |
Correct |
12 ms |
6236 KB |
Output is correct |
116 |
Correct |
15 ms |
6236 KB |
Output is correct |
117 |
Correct |
28 ms |
6236 KB |
Output is correct |
118 |
Correct |
27 ms |
6376 KB |
Output is correct |
119 |
Correct |
46 ms |
12124 KB |
Output is correct |
120 |
Correct |
56 ms |
15192 KB |
Output is correct |
121 |
Correct |
58 ms |
15700 KB |
Output is correct |
122 |
Correct |
42 ms |
15176 KB |
Output is correct |
123 |
Correct |
36 ms |
15196 KB |
Output is correct |
124 |
Correct |
192 ms |
43088 KB |
Output is correct |
125 |
Correct |
695 ms |
125492 KB |
Output is correct |
126 |
Correct |
694 ms |
147848 KB |
Output is correct |
127 |
Correct |
725 ms |
148056 KB |
Output is correct |
128 |
Correct |
533 ms |
147796 KB |
Output is correct |
129 |
Correct |
521 ms |
147792 KB |
Output is correct |
130 |
Correct |
792 ms |
148568 KB |
Output is correct |
131 |
Correct |
760 ms |
148052 KB |
Output is correct |
132 |
Correct |
24 ms |
6232 KB |
Output is correct |
133 |
Correct |
1 ms |
600 KB |
Output is correct |
134 |
Correct |
1 ms |
860 KB |
Output is correct |
135 |
Correct |
15 ms |
4188 KB |
Output is correct |
136 |
Correct |
14 ms |
7076 KB |
Output is correct |
137 |
Correct |
21 ms |
5724 KB |
Output is correct |
138 |
Correct |
24 ms |
6564 KB |
Output is correct |
139 |
Correct |
31 ms |
6232 KB |
Output is correct |
140 |
Correct |
21 ms |
6232 KB |
Output is correct |
141 |
Correct |
20 ms |
6236 KB |
Output is correct |
142 |
Correct |
16 ms |
6236 KB |
Output is correct |
143 |
Correct |
12 ms |
6380 KB |
Output is correct |
144 |
Correct |
18 ms |
9068 KB |
Output is correct |
145 |
Correct |
17 ms |
9068 KB |
Output is correct |
146 |
Correct |
18 ms |
7516 KB |
Output is correct |
147 |
Correct |
18 ms |
6492 KB |
Output is correct |
148 |
Correct |
18 ms |
6236 KB |
Output is correct |
149 |
Correct |
18 ms |
6436 KB |
Output is correct |
150 |
Correct |
15 ms |
6236 KB |
Output is correct |
151 |
Correct |
38 ms |
6400 KB |
Output is correct |
152 |
Correct |
28 ms |
6236 KB |
Output is correct |
153 |
Correct |
23 ms |
6236 KB |
Output is correct |
154 |
Correct |
65 ms |
15224 KB |
Output is correct |
155 |
Correct |
23 ms |
7768 KB |
Output is correct |
156 |
Correct |
47 ms |
12300 KB |
Output is correct |
157 |
Correct |
60 ms |
14168 KB |
Output is correct |
158 |
Correct |
59 ms |
15180 KB |
Output is correct |
159 |
Correct |
77 ms |
15196 KB |
Output is correct |
160 |
Correct |
66 ms |
15144 KB |
Output is correct |
161 |
Correct |
65 ms |
15444 KB |
Output is correct |
162 |
Correct |
39 ms |
15184 KB |
Output is correct |
163 |
Correct |
40 ms |
15192 KB |
Output is correct |
164 |
Correct |
51 ms |
22032 KB |
Output is correct |
165 |
Correct |
52 ms |
21948 KB |
Output is correct |
166 |
Correct |
55 ms |
18480 KB |
Output is correct |
167 |
Correct |
50 ms |
15440 KB |
Output is correct |
168 |
Correct |
52 ms |
15184 KB |
Output is correct |
169 |
Correct |
61 ms |
15196 KB |
Output is correct |
170 |
Correct |
63 ms |
15188 KB |
Output is correct |
171 |
Correct |
77 ms |
15196 KB |
Output is correct |
172 |
Correct |
77 ms |
15188 KB |
Output is correct |
173 |
Correct |
63 ms |
15192 KB |
Output is correct |
174 |
Correct |
95 ms |
20308 KB |
Output is correct |
175 |
Correct |
147 ms |
33616 KB |
Output is correct |
176 |
Correct |
281 ms |
87136 KB |
Output is correct |
177 |
Correct |
502 ms |
100940 KB |
Output is correct |
178 |
Correct |
767 ms |
130456 KB |
Output is correct |
179 |
Correct |
707 ms |
149432 KB |
Output is correct |
180 |
Correct |
762 ms |
148560 KB |
Output is correct |
181 |
Correct |
765 ms |
148052 KB |
Output is correct |
182 |
Correct |
887 ms |
148296 KB |
Output is correct |
183 |
Correct |
794 ms |
149408 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
1 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
600 KB |
Output is correct |
6 |
Correct |
1 ms |
348 KB |
Output is correct |
7 |
Correct |
1 ms |
348 KB |
Output is correct |
8 |
Correct |
1 ms |
348 KB |
Output is correct |
9 |
Correct |
0 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
0 ms |
348 KB |
Output is correct |
12 |
Correct |
0 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
1 ms |
344 KB |
Output is correct |
15 |
Correct |
0 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
1 ms |
348 KB |
Output is correct |
19 |
Correct |
25 ms |
6236 KB |
Output is correct |
20 |
Correct |
14 ms |
7076 KB |
Output is correct |
21 |
Correct |
20 ms |
6236 KB |
Output is correct |
22 |
Correct |
28 ms |
6236 KB |
Output is correct |
23 |
Correct |
21 ms |
6236 KB |
Output is correct |
24 |
Correct |
18 ms |
9072 KB |
Output is correct |
25 |
Correct |
17 ms |
9072 KB |
Output is correct |
26 |
Correct |
28 ms |
6236 KB |
Output is correct |
27 |
Correct |
27 ms |
6236 KB |
Output is correct |
28 |
Correct |
21 ms |
6332 KB |
Output is correct |
29 |
Correct |
64 ms |
15196 KB |
Output is correct |
30 |
Correct |
23 ms |
7768 KB |
Output is correct |
31 |
Correct |
56 ms |
15196 KB |
Output is correct |
32 |
Correct |
75 ms |
15232 KB |
Output is correct |
33 |
Correct |
70 ms |
15116 KB |
Output is correct |
34 |
Correct |
58 ms |
22236 KB |
Output is correct |
35 |
Correct |
52 ms |
21980 KB |
Output is correct |
36 |
Correct |
76 ms |
15196 KB |
Output is correct |
37 |
Correct |
79 ms |
15444 KB |
Output is correct |
38 |
Correct |
64 ms |
14996 KB |
Output is correct |
39 |
Correct |
834 ms |
147624 KB |
Output is correct |
40 |
Correct |
81 ms |
17580 KB |
Output is correct |
41 |
Correct |
77 ms |
27008 KB |
Output is correct |
42 |
Correct |
103 ms |
21340 KB |
Output is correct |
43 |
Correct |
87 ms |
29700 KB |
Output is correct |
44 |
Correct |
426 ms |
79092 KB |
Output is correct |
45 |
Correct |
408 ms |
86496 KB |
Output is correct |
46 |
Correct |
685 ms |
147796 KB |
Output is correct |
47 |
Correct |
890 ms |
147824 KB |
Output is correct |
48 |
Correct |
945 ms |
147828 KB |
Output is correct |
49 |
Correct |
586 ms |
218036 KB |
Output is correct |
50 |
Correct |
555 ms |
217928 KB |
Output is correct |
51 |
Correct |
974 ms |
147844 KB |
Output is correct |
52 |
Correct |
934 ms |
147848 KB |
Output is correct |
53 |
Correct |
892 ms |
147952 KB |
Output is correct |
54 |
Correct |
0 ms |
348 KB |
Output is correct |
55 |
Correct |
0 ms |
348 KB |
Output is correct |
56 |
Correct |
0 ms |
348 KB |
Output is correct |
57 |
Correct |
0 ms |
348 KB |
Output is correct |
58 |
Correct |
1 ms |
348 KB |
Output is correct |
59 |
Correct |
0 ms |
348 KB |
Output is correct |
60 |
Correct |
0 ms |
348 KB |
Output is correct |
61 |
Correct |
0 ms |
348 KB |
Output is correct |
62 |
Correct |
1 ms |
348 KB |
Output is correct |
63 |
Correct |
1 ms |
348 KB |
Output is correct |
64 |
Correct |
1 ms |
348 KB |
Output is correct |
65 |
Correct |
1 ms |
348 KB |
Output is correct |
66 |
Correct |
0 ms |
348 KB |
Output is correct |
67 |
Correct |
0 ms |
348 KB |
Output is correct |
68 |
Correct |
1 ms |
348 KB |
Output is correct |
69 |
Correct |
1 ms |
348 KB |
Output is correct |
70 |
Correct |
1 ms |
348 KB |
Output is correct |
71 |
Correct |
0 ms |
348 KB |
Output is correct |
72 |
Correct |
1 ms |
344 KB |
Output is correct |
73 |
Correct |
1 ms |
348 KB |
Output is correct |
74 |
Correct |
0 ms |
348 KB |
Output is correct |
75 |
Correct |
1 ms |
348 KB |
Output is correct |
76 |
Correct |
0 ms |
348 KB |
Output is correct |
77 |
Correct |
1 ms |
344 KB |
Output is correct |
78 |
Correct |
0 ms |
348 KB |
Output is correct |
79 |
Correct |
1 ms |
348 KB |
Output is correct |
80 |
Correct |
0 ms |
348 KB |
Output is correct |
81 |
Correct |
1 ms |
348 KB |
Output is correct |
82 |
Correct |
0 ms |
348 KB |
Output is correct |
83 |
Correct |
1 ms |
348 KB |
Output is correct |
84 |
Correct |
1 ms |
348 KB |
Output is correct |
85 |
Correct |
1 ms |
348 KB |
Output is correct |
86 |
Correct |
0 ms |
348 KB |
Output is correct |
87 |
Correct |
0 ms |
344 KB |
Output is correct |
88 |
Correct |
1 ms |
348 KB |
Output is correct |
89 |
Correct |
0 ms |
348 KB |
Output is correct |
90 |
Correct |
0 ms |
348 KB |
Output is correct |
91 |
Correct |
0 ms |
348 KB |
Output is correct |
92 |
Correct |
1 ms |
348 KB |
Output is correct |
93 |
Correct |
1 ms |
348 KB |
Output is correct |
94 |
Correct |
1 ms |
348 KB |
Output is correct |
95 |
Correct |
0 ms |
348 KB |
Output is correct |
96 |
Correct |
1 ms |
348 KB |
Output is correct |
97 |
Correct |
0 ms |
604 KB |
Output is correct |
98 |
Correct |
0 ms |
348 KB |
Output is correct |
99 |
Correct |
1 ms |
348 KB |
Output is correct |
100 |
Correct |
0 ms |
348 KB |
Output is correct |
101 |
Correct |
1 ms |
348 KB |
Output is correct |
102 |
Correct |
0 ms |
348 KB |
Output is correct |
103 |
Correct |
0 ms |
348 KB |
Output is correct |
104 |
Correct |
0 ms |
348 KB |
Output is correct |
105 |
Correct |
0 ms |
348 KB |
Output is correct |
106 |
Correct |
1 ms |
348 KB |
Output is correct |
107 |
Correct |
1 ms |
348 KB |
Output is correct |
108 |
Correct |
1 ms |
348 KB |
Output is correct |
109 |
Correct |
1 ms |
604 KB |
Output is correct |
110 |
Correct |
15 ms |
4228 KB |
Output is correct |
111 |
Correct |
21 ms |
5724 KB |
Output is correct |
112 |
Correct |
20 ms |
6236 KB |
Output is correct |
113 |
Correct |
23 ms |
6492 KB |
Output is correct |
114 |
Correct |
13 ms |
6236 KB |
Output is correct |
115 |
Correct |
12 ms |
6236 KB |
Output is correct |
116 |
Correct |
15 ms |
6236 KB |
Output is correct |
117 |
Correct |
28 ms |
6236 KB |
Output is correct |
118 |
Correct |
27 ms |
6376 KB |
Output is correct |
119 |
Correct |
46 ms |
12124 KB |
Output is correct |
120 |
Correct |
56 ms |
15192 KB |
Output is correct |
121 |
Correct |
58 ms |
15700 KB |
Output is correct |
122 |
Correct |
42 ms |
15176 KB |
Output is correct |
123 |
Correct |
36 ms |
15196 KB |
Output is correct |
124 |
Correct |
192 ms |
43088 KB |
Output is correct |
125 |
Correct |
695 ms |
125492 KB |
Output is correct |
126 |
Correct |
694 ms |
147848 KB |
Output is correct |
127 |
Correct |
725 ms |
148056 KB |
Output is correct |
128 |
Correct |
533 ms |
147796 KB |
Output is correct |
129 |
Correct |
521 ms |
147792 KB |
Output is correct |
130 |
Correct |
792 ms |
148568 KB |
Output is correct |
131 |
Correct |
760 ms |
148052 KB |
Output is correct |
132 |
Correct |
24 ms |
6232 KB |
Output is correct |
133 |
Correct |
1 ms |
600 KB |
Output is correct |
134 |
Correct |
1 ms |
860 KB |
Output is correct |
135 |
Correct |
15 ms |
4188 KB |
Output is correct |
136 |
Correct |
14 ms |
7076 KB |
Output is correct |
137 |
Correct |
21 ms |
5724 KB |
Output is correct |
138 |
Correct |
24 ms |
6564 KB |
Output is correct |
139 |
Correct |
31 ms |
6232 KB |
Output is correct |
140 |
Correct |
21 ms |
6232 KB |
Output is correct |
141 |
Correct |
20 ms |
6236 KB |
Output is correct |
142 |
Correct |
16 ms |
6236 KB |
Output is correct |
143 |
Correct |
12 ms |
6380 KB |
Output is correct |
144 |
Correct |
18 ms |
9068 KB |
Output is correct |
145 |
Correct |
17 ms |
9068 KB |
Output is correct |
146 |
Correct |
18 ms |
7516 KB |
Output is correct |
147 |
Correct |
18 ms |
6492 KB |
Output is correct |
148 |
Correct |
18 ms |
6236 KB |
Output is correct |
149 |
Correct |
18 ms |
6436 KB |
Output is correct |
150 |
Correct |
15 ms |
6236 KB |
Output is correct |
151 |
Correct |
38 ms |
6400 KB |
Output is correct |
152 |
Correct |
28 ms |
6236 KB |
Output is correct |
153 |
Correct |
23 ms |
6236 KB |
Output is correct |
154 |
Correct |
65 ms |
15224 KB |
Output is correct |
155 |
Correct |
23 ms |
7768 KB |
Output is correct |
156 |
Correct |
47 ms |
12300 KB |
Output is correct |
157 |
Correct |
60 ms |
14168 KB |
Output is correct |
158 |
Correct |
59 ms |
15180 KB |
Output is correct |
159 |
Correct |
77 ms |
15196 KB |
Output is correct |
160 |
Correct |
66 ms |
15144 KB |
Output is correct |
161 |
Correct |
65 ms |
15444 KB |
Output is correct |
162 |
Correct |
39 ms |
15184 KB |
Output is correct |
163 |
Correct |
40 ms |
15192 KB |
Output is correct |
164 |
Correct |
51 ms |
22032 KB |
Output is correct |
165 |
Correct |
52 ms |
21948 KB |
Output is correct |
166 |
Correct |
55 ms |
18480 KB |
Output is correct |
167 |
Correct |
50 ms |
15440 KB |
Output is correct |
168 |
Correct |
52 ms |
15184 KB |
Output is correct |
169 |
Correct |
61 ms |
15196 KB |
Output is correct |
170 |
Correct |
63 ms |
15188 KB |
Output is correct |
171 |
Correct |
77 ms |
15196 KB |
Output is correct |
172 |
Correct |
77 ms |
15188 KB |
Output is correct |
173 |
Correct |
63 ms |
15192 KB |
Output is correct |
174 |
Correct |
95 ms |
20308 KB |
Output is correct |
175 |
Correct |
147 ms |
33616 KB |
Output is correct |
176 |
Correct |
281 ms |
87136 KB |
Output is correct |
177 |
Correct |
502 ms |
100940 KB |
Output is correct |
178 |
Correct |
767 ms |
130456 KB |
Output is correct |
179 |
Correct |
707 ms |
149432 KB |
Output is correct |
180 |
Correct |
762 ms |
148560 KB |
Output is correct |
181 |
Correct |
765 ms |
148052 KB |
Output is correct |
182 |
Correct |
887 ms |
148296 KB |
Output is correct |
183 |
Correct |
794 ms |
149408 KB |
Output is correct |
184 |
Correct |
1782 ms |
295236 KB |
Output is correct |
185 |
Correct |
750 ms |
164248 KB |
Output is correct |
186 |
Correct |
938 ms |
170020 KB |
Output is correct |
187 |
Correct |
1249 ms |
210308 KB |
Output is correct |
188 |
Correct |
1511 ms |
295544 KB |
Output is correct |
189 |
Correct |
1922 ms |
295156 KB |
Output is correct |
190 |
Correct |
1911 ms |
295148 KB |
Output is correct |
191 |
Correct |
1727 ms |
295396 KB |
Output is correct |
192 |
Correct |
1489 ms |
295140 KB |
Output is correct |
193 |
Correct |
1426 ms |
295136 KB |
Output is correct |
194 |
Correct |
1347 ms |
435492 KB |
Output is correct |
195 |
Correct |
1122 ms |
435484 KB |
Output is correct |
196 |
Correct |
1742 ms |
297364 KB |
Output is correct |
197 |
Correct |
1797 ms |
296496 KB |
Output is correct |
198 |
Correct |
1670 ms |
295720 KB |
Output is correct |
199 |
Execution timed out |
2108 ms |
295460 KB |
Time limit exceeded |
200 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
348 KB |
Output is correct |
2 |
Correct |
0 ms |
348 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
1 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
600 KB |
Output is correct |
6 |
Correct |
1 ms |
348 KB |
Output is correct |
7 |
Correct |
1 ms |
348 KB |
Output is correct |
8 |
Correct |
1 ms |
348 KB |
Output is correct |
9 |
Correct |
0 ms |
348 KB |
Output is correct |
10 |
Correct |
1 ms |
348 KB |
Output is correct |
11 |
Correct |
0 ms |
348 KB |
Output is correct |
12 |
Correct |
0 ms |
348 KB |
Output is correct |
13 |
Correct |
0 ms |
348 KB |
Output is correct |
14 |
Correct |
1 ms |
344 KB |
Output is correct |
15 |
Correct |
0 ms |
348 KB |
Output is correct |
16 |
Correct |
1 ms |
348 KB |
Output is correct |
17 |
Correct |
1 ms |
348 KB |
Output is correct |
18 |
Correct |
1 ms |
348 KB |
Output is correct |
19 |
Correct |
25 ms |
6236 KB |
Output is correct |
20 |
Correct |
14 ms |
7076 KB |
Output is correct |
21 |
Correct |
20 ms |
6236 KB |
Output is correct |
22 |
Correct |
28 ms |
6236 KB |
Output is correct |
23 |
Correct |
21 ms |
6236 KB |
Output is correct |
24 |
Correct |
18 ms |
9072 KB |
Output is correct |
25 |
Correct |
17 ms |
9072 KB |
Output is correct |
26 |
Correct |
28 ms |
6236 KB |
Output is correct |
27 |
Correct |
27 ms |
6236 KB |
Output is correct |
28 |
Correct |
21 ms |
6332 KB |
Output is correct |
29 |
Correct |
64 ms |
15196 KB |
Output is correct |
30 |
Correct |
23 ms |
7768 KB |
Output is correct |
31 |
Correct |
56 ms |
15196 KB |
Output is correct |
32 |
Correct |
75 ms |
15232 KB |
Output is correct |
33 |
Correct |
70 ms |
15116 KB |
Output is correct |
34 |
Correct |
58 ms |
22236 KB |
Output is correct |
35 |
Correct |
52 ms |
21980 KB |
Output is correct |
36 |
Correct |
76 ms |
15196 KB |
Output is correct |
37 |
Correct |
79 ms |
15444 KB |
Output is correct |
38 |
Correct |
64 ms |
14996 KB |
Output is correct |
39 |
Correct |
834 ms |
147624 KB |
Output is correct |
40 |
Correct |
81 ms |
17580 KB |
Output is correct |
41 |
Correct |
77 ms |
27008 KB |
Output is correct |
42 |
Correct |
103 ms |
21340 KB |
Output is correct |
43 |
Correct |
87 ms |
29700 KB |
Output is correct |
44 |
Correct |
426 ms |
79092 KB |
Output is correct |
45 |
Correct |
408 ms |
86496 KB |
Output is correct |
46 |
Correct |
685 ms |
147796 KB |
Output is correct |
47 |
Correct |
890 ms |
147824 KB |
Output is correct |
48 |
Correct |
945 ms |
147828 KB |
Output is correct |
49 |
Correct |
586 ms |
218036 KB |
Output is correct |
50 |
Correct |
555 ms |
217928 KB |
Output is correct |
51 |
Correct |
974 ms |
147844 KB |
Output is correct |
52 |
Correct |
934 ms |
147848 KB |
Output is correct |
53 |
Correct |
892 ms |
147952 KB |
Output is correct |
54 |
Correct |
0 ms |
348 KB |
Output is correct |
55 |
Correct |
0 ms |
348 KB |
Output is correct |
56 |
Correct |
0 ms |
348 KB |
Output is correct |
57 |
Correct |
0 ms |
348 KB |
Output is correct |
58 |
Correct |
1 ms |
348 KB |
Output is correct |
59 |
Correct |
0 ms |
348 KB |
Output is correct |
60 |
Correct |
0 ms |
348 KB |
Output is correct |
61 |
Correct |
0 ms |
348 KB |
Output is correct |
62 |
Correct |
1 ms |
348 KB |
Output is correct |
63 |
Correct |
1 ms |
348 KB |
Output is correct |
64 |
Correct |
1 ms |
348 KB |
Output is correct |
65 |
Correct |
1 ms |
348 KB |
Output is correct |
66 |
Correct |
0 ms |
348 KB |
Output is correct |
67 |
Correct |
0 ms |
348 KB |
Output is correct |
68 |
Correct |
1 ms |
348 KB |
Output is correct |
69 |
Correct |
1 ms |
348 KB |
Output is correct |
70 |
Correct |
1 ms |
348 KB |
Output is correct |
71 |
Correct |
0 ms |
348 KB |
Output is correct |
72 |
Correct |
1 ms |
344 KB |
Output is correct |
73 |
Correct |
1 ms |
348 KB |
Output is correct |
74 |
Correct |
0 ms |
348 KB |
Output is correct |
75 |
Correct |
1 ms |
348 KB |
Output is correct |
76 |
Correct |
0 ms |
348 KB |
Output is correct |
77 |
Correct |
1 ms |
344 KB |
Output is correct |
78 |
Correct |
0 ms |
348 KB |
Output is correct |
79 |
Correct |
1 ms |
348 KB |
Output is correct |
80 |
Correct |
0 ms |
348 KB |
Output is correct |
81 |
Correct |
1 ms |
348 KB |
Output is correct |
82 |
Correct |
0 ms |
348 KB |
Output is correct |
83 |
Correct |
1 ms |
348 KB |
Output is correct |
84 |
Correct |
1 ms |
348 KB |
Output is correct |
85 |
Correct |
1 ms |
348 KB |
Output is correct |
86 |
Correct |
0 ms |
348 KB |
Output is correct |
87 |
Correct |
0 ms |
344 KB |
Output is correct |
88 |
Correct |
1 ms |
348 KB |
Output is correct |
89 |
Correct |
0 ms |
348 KB |
Output is correct |
90 |
Correct |
0 ms |
348 KB |
Output is correct |
91 |
Correct |
0 ms |
348 KB |
Output is correct |
92 |
Correct |
1 ms |
348 KB |
Output is correct |
93 |
Correct |
1 ms |
348 KB |
Output is correct |
94 |
Correct |
1 ms |
348 KB |
Output is correct |
95 |
Correct |
0 ms |
348 KB |
Output is correct |
96 |
Correct |
1 ms |
348 KB |
Output is correct |
97 |
Correct |
0 ms |
604 KB |
Output is correct |
98 |
Correct |
0 ms |
348 KB |
Output is correct |
99 |
Correct |
1 ms |
348 KB |
Output is correct |
100 |
Correct |
0 ms |
348 KB |
Output is correct |
101 |
Correct |
1 ms |
348 KB |
Output is correct |
102 |
Correct |
0 ms |
348 KB |
Output is correct |
103 |
Correct |
0 ms |
348 KB |
Output is correct |
104 |
Correct |
0 ms |
348 KB |
Output is correct |
105 |
Correct |
0 ms |
348 KB |
Output is correct |
106 |
Correct |
1 ms |
348 KB |
Output is correct |
107 |
Correct |
1 ms |
348 KB |
Output is correct |
108 |
Correct |
1 ms |
348 KB |
Output is correct |
109 |
Correct |
1 ms |
604 KB |
Output is correct |
110 |
Correct |
15 ms |
4228 KB |
Output is correct |
111 |
Correct |
21 ms |
5724 KB |
Output is correct |
112 |
Correct |
20 ms |
6236 KB |
Output is correct |
113 |
Correct |
23 ms |
6492 KB |
Output is correct |
114 |
Correct |
13 ms |
6236 KB |
Output is correct |
115 |
Correct |
12 ms |
6236 KB |
Output is correct |
116 |
Correct |
15 ms |
6236 KB |
Output is correct |
117 |
Correct |
28 ms |
6236 KB |
Output is correct |
118 |
Correct |
27 ms |
6376 KB |
Output is correct |
119 |
Correct |
46 ms |
12124 KB |
Output is correct |
120 |
Correct |
56 ms |
15192 KB |
Output is correct |
121 |
Correct |
58 ms |
15700 KB |
Output is correct |
122 |
Correct |
42 ms |
15176 KB |
Output is correct |
123 |
Correct |
36 ms |
15196 KB |
Output is correct |
124 |
Correct |
192 ms |
43088 KB |
Output is correct |
125 |
Correct |
695 ms |
125492 KB |
Output is correct |
126 |
Correct |
694 ms |
147848 KB |
Output is correct |
127 |
Correct |
725 ms |
148056 KB |
Output is correct |
128 |
Correct |
533 ms |
147796 KB |
Output is correct |
129 |
Correct |
521 ms |
147792 KB |
Output is correct |
130 |
Correct |
792 ms |
148568 KB |
Output is correct |
131 |
Correct |
760 ms |
148052 KB |
Output is correct |
132 |
Correct |
24 ms |
6232 KB |
Output is correct |
133 |
Correct |
1 ms |
600 KB |
Output is correct |
134 |
Correct |
1 ms |
860 KB |
Output is correct |
135 |
Correct |
15 ms |
4188 KB |
Output is correct |
136 |
Correct |
14 ms |
7076 KB |
Output is correct |
137 |
Correct |
21 ms |
5724 KB |
Output is correct |
138 |
Correct |
24 ms |
6564 KB |
Output is correct |
139 |
Correct |
31 ms |
6232 KB |
Output is correct |
140 |
Correct |
21 ms |
6232 KB |
Output is correct |
141 |
Correct |
20 ms |
6236 KB |
Output is correct |
142 |
Correct |
16 ms |
6236 KB |
Output is correct |
143 |
Correct |
12 ms |
6380 KB |
Output is correct |
144 |
Correct |
18 ms |
9068 KB |
Output is correct |
145 |
Correct |
17 ms |
9068 KB |
Output is correct |
146 |
Correct |
18 ms |
7516 KB |
Output is correct |
147 |
Correct |
18 ms |
6492 KB |
Output is correct |
148 |
Correct |
18 ms |
6236 KB |
Output is correct |
149 |
Correct |
18 ms |
6436 KB |
Output is correct |
150 |
Correct |
15 ms |
6236 KB |
Output is correct |
151 |
Correct |
38 ms |
6400 KB |
Output is correct |
152 |
Correct |
28 ms |
6236 KB |
Output is correct |
153 |
Correct |
23 ms |
6236 KB |
Output is correct |
154 |
Correct |
65 ms |
15224 KB |
Output is correct |
155 |
Correct |
23 ms |
7768 KB |
Output is correct |
156 |
Correct |
47 ms |
12300 KB |
Output is correct |
157 |
Correct |
60 ms |
14168 KB |
Output is correct |
158 |
Correct |
59 ms |
15180 KB |
Output is correct |
159 |
Correct |
77 ms |
15196 KB |
Output is correct |
160 |
Correct |
66 ms |
15144 KB |
Output is correct |
161 |
Correct |
65 ms |
15444 KB |
Output is correct |
162 |
Correct |
39 ms |
15184 KB |
Output is correct |
163 |
Correct |
40 ms |
15192 KB |
Output is correct |
164 |
Correct |
51 ms |
22032 KB |
Output is correct |
165 |
Correct |
52 ms |
21948 KB |
Output is correct |
166 |
Correct |
55 ms |
18480 KB |
Output is correct |
167 |
Correct |
50 ms |
15440 KB |
Output is correct |
168 |
Correct |
52 ms |
15184 KB |
Output is correct |
169 |
Correct |
61 ms |
15196 KB |
Output is correct |
170 |
Correct |
63 ms |
15188 KB |
Output is correct |
171 |
Correct |
77 ms |
15196 KB |
Output is correct |
172 |
Correct |
77 ms |
15188 KB |
Output is correct |
173 |
Correct |
63 ms |
15192 KB |
Output is correct |
174 |
Correct |
95 ms |
20308 KB |
Output is correct |
175 |
Correct |
147 ms |
33616 KB |
Output is correct |
176 |
Correct |
281 ms |
87136 KB |
Output is correct |
177 |
Correct |
502 ms |
100940 KB |
Output is correct |
178 |
Correct |
767 ms |
130456 KB |
Output is correct |
179 |
Correct |
707 ms |
149432 KB |
Output is correct |
180 |
Correct |
762 ms |
148560 KB |
Output is correct |
181 |
Correct |
765 ms |
148052 KB |
Output is correct |
182 |
Correct |
887 ms |
148296 KB |
Output is correct |
183 |
Correct |
794 ms |
149408 KB |
Output is correct |
184 |
Correct |
1782 ms |
295236 KB |
Output is correct |
185 |
Correct |
750 ms |
164248 KB |
Output is correct |
186 |
Correct |
938 ms |
170020 KB |
Output is correct |
187 |
Correct |
1249 ms |
210308 KB |
Output is correct |
188 |
Correct |
1511 ms |
295544 KB |
Output is correct |
189 |
Correct |
1922 ms |
295156 KB |
Output is correct |
190 |
Correct |
1911 ms |
295148 KB |
Output is correct |
191 |
Correct |
1727 ms |
295396 KB |
Output is correct |
192 |
Correct |
1489 ms |
295140 KB |
Output is correct |
193 |
Correct |
1426 ms |
295136 KB |
Output is correct |
194 |
Correct |
1347 ms |
435492 KB |
Output is correct |
195 |
Correct |
1122 ms |
435484 KB |
Output is correct |
196 |
Correct |
1742 ms |
297364 KB |
Output is correct |
197 |
Correct |
1797 ms |
296496 KB |
Output is correct |
198 |
Correct |
1670 ms |
295720 KB |
Output is correct |
199 |
Execution timed out |
2108 ms |
295460 KB |
Time limit exceeded |
200 |
Halted |
0 ms |
0 KB |
- |