# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
736270 |
2023-05-05T11:36:52 Z |
Cookie |
Maze (JOI23_ho_t3) |
C++14 |
|
2000 ms |
20888 KB |
#include<bits/stdc++.h>
#include<fstream>
using namespace std;
ifstream fin("WINTER.inp");
ofstream fout("WINTER.out");
#define ll long long
#define pb push_back
#define forr(i, a, b) for(int i = a; i < b; i++)
#define dorr(i, a, b) for(int i = a; i >= b; i--)
#define ld long double
#define vt vector
#include<fstream>
#define fi first
#define se second
#define pll pair<ll, ll>
#define pii pair<int, int>
const ld PI = 3.14159265359;
const int x[4] = {1, -1, 0, 0};
const int y[4] = {0, 0, 1, -1};
const ll mod = 1e9 + 7;
const int mxn = 5e5, mxm = 1e5, sq = 400;
const int base = (1 << 18);
const ll inf = 1e9;
const ld pre = 1e-6;
int r, c, n, sti, stj, eni, enj;
vt<vt<char>>a;
vt<vt<int>>d;
bool inside(int i, int j){
return(i >= 1 && j >= 1 && i <= r && j <= c);
}
signed main(){
ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
cin >> r >> c >> n;
a.resize(r + 1, vt<char>(c + 1));
d.resize(r + 1, vt<int>(c + 1));
cin >> sti >> stj >> eni >> enj;
forr(i, 1, r + 1){
forr(j, 1, c + 1){
cin >> a[i][j]; d[i][j] = 1e9;
}
}
deque<pair<int, int>>dq; dq.pb({sti, stj});
d[sti][stj] = 0;
while(!dq.empty()){
auto [i, j] = dq.front(); dq.pop_front();
if(a[i][j] == '.'){
for(int t = 0; t < 4; t++){
int nwi = i + x[t], nwj = j + y[t];
if(inside(nwi, nwj)){
if(d[nwi][nwj] > d[i][j]){
d[nwi][nwj] = d[i][j];
dq.push_front({nwi, nwj});
}
}
}
}
for(int ii = i - n; ii <= i + n; ii++){
for(int jj = j - n; jj <= j + n; jj++){
bool ok1 = (ii == i - n || ii == i + n);
bool ok2 = (jj == j - n || jj == j + n);
if(ok1 && ok2)continue;
if(inside(ii, jj)){
if(d[ii][jj] > d[i][j] + 1){
d[ii][jj] = d[i][j] + 1;
dq.push_back({ii, jj});
}
}
}
}
}
cout << d[eni][enj];
return(0);
}
Compilation message
Main.cpp: In function 'int main()':
Main.cpp:46:14: warning: structured bindings only available with '-std=c++17' or '-std=gnu++17'
46 | auto [i, j] = dq.front(); dq.pop_front();
| ^
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
340 KB |
Output is correct |
8 |
Correct |
0 ms |
340 KB |
Output is correct |
9 |
Correct |
1 ms |
324 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
0 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
324 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
4 ms |
596 KB |
Output is correct |
20 |
Correct |
3 ms |
980 KB |
Output is correct |
21 |
Correct |
4 ms |
852 KB |
Output is correct |
22 |
Correct |
5 ms |
596 KB |
Output is correct |
23 |
Correct |
3 ms |
596 KB |
Output is correct |
24 |
Correct |
5 ms |
1232 KB |
Output is correct |
25 |
Correct |
4 ms |
1236 KB |
Output is correct |
26 |
Correct |
5 ms |
592 KB |
Output is correct |
27 |
Correct |
5 ms |
596 KB |
Output is correct |
28 |
Correct |
4 ms |
596 KB |
Output is correct |
29 |
Correct |
9 ms |
1108 KB |
Output is correct |
30 |
Correct |
5 ms |
956 KB |
Output is correct |
31 |
Correct |
10 ms |
1620 KB |
Output is correct |
32 |
Correct |
12 ms |
1232 KB |
Output is correct |
33 |
Correct |
9 ms |
1108 KB |
Output is correct |
34 |
Correct |
9 ms |
2368 KB |
Output is correct |
35 |
Correct |
9 ms |
2368 KB |
Output is correct |
36 |
Correct |
13 ms |
1236 KB |
Output is correct |
37 |
Correct |
17 ms |
1104 KB |
Output is correct |
38 |
Correct |
8 ms |
1236 KB |
Output is correct |
39 |
Correct |
100 ms |
7868 KB |
Output is correct |
40 |
Correct |
14 ms |
1296 KB |
Output is correct |
41 |
Correct |
12 ms |
2844 KB |
Output is correct |
42 |
Correct |
21 ms |
1420 KB |
Output is correct |
43 |
Correct |
24 ms |
2644 KB |
Output is correct |
44 |
Correct |
60 ms |
5076 KB |
Output is correct |
45 |
Correct |
49 ms |
5684 KB |
Output is correct |
46 |
Correct |
104 ms |
11996 KB |
Output is correct |
47 |
Correct |
117 ms |
8056 KB |
Output is correct |
48 |
Correct |
93 ms |
8844 KB |
Output is correct |
49 |
Correct |
87 ms |
20864 KB |
Output is correct |
50 |
Correct |
75 ms |
20888 KB |
Output is correct |
51 |
Correct |
127 ms |
9296 KB |
Output is correct |
52 |
Correct |
125 ms |
8716 KB |
Output is correct |
53 |
Correct |
86 ms |
8932 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
0 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
324 KB |
Output is correct |
9 |
Correct |
1 ms |
340 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
23 ms |
340 KB |
Output is correct |
13 |
Correct |
10 ms |
340 KB |
Output is correct |
14 |
Correct |
11 ms |
344 KB |
Output is correct |
15 |
Correct |
1 ms |
340 KB |
Output is correct |
16 |
Correct |
1 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
224 KB |
Output is correct |
24 |
Correct |
0 ms |
212 KB |
Output is correct |
25 |
Correct |
0 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
328 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
340 KB |
Output is correct |
31 |
Correct |
1 ms |
340 KB |
Output is correct |
32 |
Correct |
1 ms |
340 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
212 KB |
Output is correct |
2 |
Correct |
0 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
0 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
19 ms |
340 KB |
Output is correct |
10 |
Correct |
10 ms |
348 KB |
Output is correct |
11 |
Correct |
10 ms |
340 KB |
Output is correct |
12 |
Correct |
1 ms |
340 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
332 KB |
Output is correct |
16 |
Correct |
1 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
328 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
340 KB |
Output is correct |
23 |
Correct |
1 ms |
340 KB |
Output is correct |
24 |
Correct |
15 ms |
360 KB |
Output is correct |
25 |
Correct |
8 ms |
560 KB |
Output is correct |
26 |
Correct |
40 ms |
1164 KB |
Output is correct |
27 |
Correct |
7 ms |
852 KB |
Output is correct |
28 |
Execution timed out |
2059 ms |
1192 KB |
Time limit exceeded |
29 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
0 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
324 KB |
Output is correct |
9 |
Correct |
1 ms |
340 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
23 ms |
340 KB |
Output is correct |
13 |
Correct |
10 ms |
340 KB |
Output is correct |
14 |
Correct |
11 ms |
344 KB |
Output is correct |
15 |
Correct |
1 ms |
340 KB |
Output is correct |
16 |
Correct |
1 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
224 KB |
Output is correct |
24 |
Correct |
0 ms |
212 KB |
Output is correct |
25 |
Correct |
0 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
328 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
340 KB |
Output is correct |
31 |
Correct |
1 ms |
340 KB |
Output is correct |
32 |
Correct |
1 ms |
340 KB |
Output is correct |
33 |
Correct |
4 ms |
596 KB |
Output is correct |
34 |
Correct |
16 ms |
356 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
10 ms |
540 KB |
Output is correct |
37 |
Correct |
5 ms |
980 KB |
Output is correct |
38 |
Correct |
41 ms |
1132 KB |
Output is correct |
39 |
Correct |
5 ms |
852 KB |
Output is correct |
40 |
Correct |
5 ms |
596 KB |
Output is correct |
41 |
Correct |
4 ms |
596 KB |
Output is correct |
42 |
Execution timed out |
2059 ms |
1188 KB |
Time limit exceeded |
43 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
0 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
212 KB |
Output is correct |
8 |
Correct |
1 ms |
324 KB |
Output is correct |
9 |
Correct |
1 ms |
340 KB |
Output is correct |
10 |
Correct |
1 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
23 ms |
340 KB |
Output is correct |
13 |
Correct |
10 ms |
340 KB |
Output is correct |
14 |
Correct |
11 ms |
344 KB |
Output is correct |
15 |
Correct |
1 ms |
340 KB |
Output is correct |
16 |
Correct |
1 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
1 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
1 ms |
212 KB |
Output is correct |
23 |
Correct |
1 ms |
224 KB |
Output is correct |
24 |
Correct |
0 ms |
212 KB |
Output is correct |
25 |
Correct |
0 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
1 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
328 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
340 KB |
Output is correct |
31 |
Correct |
1 ms |
340 KB |
Output is correct |
32 |
Correct |
1 ms |
340 KB |
Output is correct |
33 |
Correct |
4 ms |
596 KB |
Output is correct |
34 |
Correct |
16 ms |
356 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
10 ms |
540 KB |
Output is correct |
37 |
Correct |
5 ms |
980 KB |
Output is correct |
38 |
Correct |
41 ms |
1132 KB |
Output is correct |
39 |
Correct |
5 ms |
852 KB |
Output is correct |
40 |
Correct |
5 ms |
596 KB |
Output is correct |
41 |
Correct |
4 ms |
596 KB |
Output is correct |
42 |
Execution timed out |
2059 ms |
1188 KB |
Time limit exceeded |
43 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
340 KB |
Output is correct |
8 |
Correct |
0 ms |
340 KB |
Output is correct |
9 |
Correct |
1 ms |
324 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
0 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
324 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
4 ms |
596 KB |
Output is correct |
20 |
Correct |
3 ms |
980 KB |
Output is correct |
21 |
Correct |
4 ms |
852 KB |
Output is correct |
22 |
Correct |
5 ms |
596 KB |
Output is correct |
23 |
Correct |
3 ms |
596 KB |
Output is correct |
24 |
Correct |
5 ms |
1232 KB |
Output is correct |
25 |
Correct |
4 ms |
1236 KB |
Output is correct |
26 |
Correct |
5 ms |
592 KB |
Output is correct |
27 |
Correct |
5 ms |
596 KB |
Output is correct |
28 |
Correct |
4 ms |
596 KB |
Output is correct |
29 |
Correct |
9 ms |
1108 KB |
Output is correct |
30 |
Correct |
5 ms |
956 KB |
Output is correct |
31 |
Correct |
10 ms |
1620 KB |
Output is correct |
32 |
Correct |
12 ms |
1232 KB |
Output is correct |
33 |
Correct |
9 ms |
1108 KB |
Output is correct |
34 |
Correct |
9 ms |
2368 KB |
Output is correct |
35 |
Correct |
9 ms |
2368 KB |
Output is correct |
36 |
Correct |
13 ms |
1236 KB |
Output is correct |
37 |
Correct |
17 ms |
1104 KB |
Output is correct |
38 |
Correct |
8 ms |
1236 KB |
Output is correct |
39 |
Correct |
100 ms |
7868 KB |
Output is correct |
40 |
Correct |
14 ms |
1296 KB |
Output is correct |
41 |
Correct |
12 ms |
2844 KB |
Output is correct |
42 |
Correct |
21 ms |
1420 KB |
Output is correct |
43 |
Correct |
24 ms |
2644 KB |
Output is correct |
44 |
Correct |
60 ms |
5076 KB |
Output is correct |
45 |
Correct |
49 ms |
5684 KB |
Output is correct |
46 |
Correct |
104 ms |
11996 KB |
Output is correct |
47 |
Correct |
117 ms |
8056 KB |
Output is correct |
48 |
Correct |
93 ms |
8844 KB |
Output is correct |
49 |
Correct |
87 ms |
20864 KB |
Output is correct |
50 |
Correct |
75 ms |
20888 KB |
Output is correct |
51 |
Correct |
127 ms |
9296 KB |
Output is correct |
52 |
Correct |
125 ms |
8716 KB |
Output is correct |
53 |
Correct |
86 ms |
8932 KB |
Output is correct |
54 |
Correct |
1 ms |
212 KB |
Output is correct |
55 |
Correct |
1 ms |
212 KB |
Output is correct |
56 |
Correct |
1 ms |
212 KB |
Output is correct |
57 |
Correct |
1 ms |
212 KB |
Output is correct |
58 |
Correct |
1 ms |
212 KB |
Output is correct |
59 |
Correct |
0 ms |
212 KB |
Output is correct |
60 |
Correct |
1 ms |
212 KB |
Output is correct |
61 |
Correct |
1 ms |
324 KB |
Output is correct |
62 |
Correct |
1 ms |
340 KB |
Output is correct |
63 |
Correct |
1 ms |
212 KB |
Output is correct |
64 |
Correct |
1 ms |
212 KB |
Output is correct |
65 |
Correct |
23 ms |
340 KB |
Output is correct |
66 |
Correct |
10 ms |
340 KB |
Output is correct |
67 |
Correct |
11 ms |
344 KB |
Output is correct |
68 |
Correct |
1 ms |
340 KB |
Output is correct |
69 |
Correct |
1 ms |
340 KB |
Output is correct |
70 |
Correct |
1 ms |
340 KB |
Output is correct |
71 |
Correct |
1 ms |
212 KB |
Output is correct |
72 |
Correct |
1 ms |
212 KB |
Output is correct |
73 |
Correct |
1 ms |
212 KB |
Output is correct |
74 |
Correct |
1 ms |
212 KB |
Output is correct |
75 |
Correct |
1 ms |
212 KB |
Output is correct |
76 |
Correct |
1 ms |
224 KB |
Output is correct |
77 |
Correct |
0 ms |
212 KB |
Output is correct |
78 |
Correct |
0 ms |
212 KB |
Output is correct |
79 |
Correct |
1 ms |
212 KB |
Output is correct |
80 |
Correct |
1 ms |
212 KB |
Output is correct |
81 |
Correct |
1 ms |
328 KB |
Output is correct |
82 |
Correct |
1 ms |
212 KB |
Output is correct |
83 |
Correct |
1 ms |
340 KB |
Output is correct |
84 |
Correct |
1 ms |
340 KB |
Output is correct |
85 |
Correct |
1 ms |
340 KB |
Output is correct |
86 |
Correct |
0 ms |
212 KB |
Output is correct |
87 |
Correct |
0 ms |
212 KB |
Output is correct |
88 |
Correct |
1 ms |
212 KB |
Output is correct |
89 |
Correct |
0 ms |
212 KB |
Output is correct |
90 |
Correct |
1 ms |
212 KB |
Output is correct |
91 |
Correct |
1 ms |
212 KB |
Output is correct |
92 |
Correct |
1 ms |
212 KB |
Output is correct |
93 |
Correct |
1 ms |
212 KB |
Output is correct |
94 |
Correct |
19 ms |
340 KB |
Output is correct |
95 |
Correct |
10 ms |
348 KB |
Output is correct |
96 |
Correct |
10 ms |
340 KB |
Output is correct |
97 |
Correct |
1 ms |
340 KB |
Output is correct |
98 |
Correct |
1 ms |
212 KB |
Output is correct |
99 |
Correct |
1 ms |
212 KB |
Output is correct |
100 |
Correct |
1 ms |
332 KB |
Output is correct |
101 |
Correct |
1 ms |
212 KB |
Output is correct |
102 |
Correct |
1 ms |
328 KB |
Output is correct |
103 |
Correct |
1 ms |
212 KB |
Output is correct |
104 |
Correct |
1 ms |
212 KB |
Output is correct |
105 |
Correct |
1 ms |
212 KB |
Output is correct |
106 |
Correct |
1 ms |
212 KB |
Output is correct |
107 |
Correct |
1 ms |
340 KB |
Output is correct |
108 |
Correct |
1 ms |
340 KB |
Output is correct |
109 |
Correct |
15 ms |
360 KB |
Output is correct |
110 |
Correct |
8 ms |
560 KB |
Output is correct |
111 |
Correct |
40 ms |
1164 KB |
Output is correct |
112 |
Correct |
7 ms |
852 KB |
Output is correct |
113 |
Execution timed out |
2059 ms |
1192 KB |
Time limit exceeded |
114 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
340 KB |
Output is correct |
8 |
Correct |
0 ms |
340 KB |
Output is correct |
9 |
Correct |
1 ms |
324 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
0 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
324 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
4 ms |
596 KB |
Output is correct |
20 |
Correct |
3 ms |
980 KB |
Output is correct |
21 |
Correct |
4 ms |
852 KB |
Output is correct |
22 |
Correct |
5 ms |
596 KB |
Output is correct |
23 |
Correct |
3 ms |
596 KB |
Output is correct |
24 |
Correct |
5 ms |
1232 KB |
Output is correct |
25 |
Correct |
4 ms |
1236 KB |
Output is correct |
26 |
Correct |
5 ms |
592 KB |
Output is correct |
27 |
Correct |
5 ms |
596 KB |
Output is correct |
28 |
Correct |
4 ms |
596 KB |
Output is correct |
29 |
Correct |
9 ms |
1108 KB |
Output is correct |
30 |
Correct |
5 ms |
956 KB |
Output is correct |
31 |
Correct |
10 ms |
1620 KB |
Output is correct |
32 |
Correct |
12 ms |
1232 KB |
Output is correct |
33 |
Correct |
9 ms |
1108 KB |
Output is correct |
34 |
Correct |
9 ms |
2368 KB |
Output is correct |
35 |
Correct |
9 ms |
2368 KB |
Output is correct |
36 |
Correct |
13 ms |
1236 KB |
Output is correct |
37 |
Correct |
17 ms |
1104 KB |
Output is correct |
38 |
Correct |
8 ms |
1236 KB |
Output is correct |
39 |
Correct |
100 ms |
7868 KB |
Output is correct |
40 |
Correct |
14 ms |
1296 KB |
Output is correct |
41 |
Correct |
12 ms |
2844 KB |
Output is correct |
42 |
Correct |
21 ms |
1420 KB |
Output is correct |
43 |
Correct |
24 ms |
2644 KB |
Output is correct |
44 |
Correct |
60 ms |
5076 KB |
Output is correct |
45 |
Correct |
49 ms |
5684 KB |
Output is correct |
46 |
Correct |
104 ms |
11996 KB |
Output is correct |
47 |
Correct |
117 ms |
8056 KB |
Output is correct |
48 |
Correct |
93 ms |
8844 KB |
Output is correct |
49 |
Correct |
87 ms |
20864 KB |
Output is correct |
50 |
Correct |
75 ms |
20888 KB |
Output is correct |
51 |
Correct |
127 ms |
9296 KB |
Output is correct |
52 |
Correct |
125 ms |
8716 KB |
Output is correct |
53 |
Correct |
86 ms |
8932 KB |
Output is correct |
54 |
Correct |
1 ms |
212 KB |
Output is correct |
55 |
Correct |
1 ms |
212 KB |
Output is correct |
56 |
Correct |
1 ms |
212 KB |
Output is correct |
57 |
Correct |
1 ms |
212 KB |
Output is correct |
58 |
Correct |
1 ms |
212 KB |
Output is correct |
59 |
Correct |
0 ms |
212 KB |
Output is correct |
60 |
Correct |
1 ms |
212 KB |
Output is correct |
61 |
Correct |
1 ms |
324 KB |
Output is correct |
62 |
Correct |
1 ms |
340 KB |
Output is correct |
63 |
Correct |
1 ms |
212 KB |
Output is correct |
64 |
Correct |
1 ms |
212 KB |
Output is correct |
65 |
Correct |
23 ms |
340 KB |
Output is correct |
66 |
Correct |
10 ms |
340 KB |
Output is correct |
67 |
Correct |
11 ms |
344 KB |
Output is correct |
68 |
Correct |
1 ms |
340 KB |
Output is correct |
69 |
Correct |
1 ms |
340 KB |
Output is correct |
70 |
Correct |
1 ms |
340 KB |
Output is correct |
71 |
Correct |
1 ms |
212 KB |
Output is correct |
72 |
Correct |
1 ms |
212 KB |
Output is correct |
73 |
Correct |
1 ms |
212 KB |
Output is correct |
74 |
Correct |
1 ms |
212 KB |
Output is correct |
75 |
Correct |
1 ms |
212 KB |
Output is correct |
76 |
Correct |
1 ms |
224 KB |
Output is correct |
77 |
Correct |
0 ms |
212 KB |
Output is correct |
78 |
Correct |
0 ms |
212 KB |
Output is correct |
79 |
Correct |
1 ms |
212 KB |
Output is correct |
80 |
Correct |
1 ms |
212 KB |
Output is correct |
81 |
Correct |
1 ms |
328 KB |
Output is correct |
82 |
Correct |
1 ms |
212 KB |
Output is correct |
83 |
Correct |
1 ms |
340 KB |
Output is correct |
84 |
Correct |
1 ms |
340 KB |
Output is correct |
85 |
Correct |
1 ms |
340 KB |
Output is correct |
86 |
Correct |
0 ms |
212 KB |
Output is correct |
87 |
Correct |
0 ms |
212 KB |
Output is correct |
88 |
Correct |
1 ms |
212 KB |
Output is correct |
89 |
Correct |
0 ms |
212 KB |
Output is correct |
90 |
Correct |
1 ms |
212 KB |
Output is correct |
91 |
Correct |
1 ms |
212 KB |
Output is correct |
92 |
Correct |
1 ms |
212 KB |
Output is correct |
93 |
Correct |
1 ms |
212 KB |
Output is correct |
94 |
Correct |
19 ms |
340 KB |
Output is correct |
95 |
Correct |
10 ms |
348 KB |
Output is correct |
96 |
Correct |
10 ms |
340 KB |
Output is correct |
97 |
Correct |
1 ms |
340 KB |
Output is correct |
98 |
Correct |
1 ms |
212 KB |
Output is correct |
99 |
Correct |
1 ms |
212 KB |
Output is correct |
100 |
Correct |
1 ms |
332 KB |
Output is correct |
101 |
Correct |
1 ms |
212 KB |
Output is correct |
102 |
Correct |
1 ms |
328 KB |
Output is correct |
103 |
Correct |
1 ms |
212 KB |
Output is correct |
104 |
Correct |
1 ms |
212 KB |
Output is correct |
105 |
Correct |
1 ms |
212 KB |
Output is correct |
106 |
Correct |
1 ms |
212 KB |
Output is correct |
107 |
Correct |
1 ms |
340 KB |
Output is correct |
108 |
Correct |
1 ms |
340 KB |
Output is correct |
109 |
Correct |
15 ms |
360 KB |
Output is correct |
110 |
Correct |
8 ms |
560 KB |
Output is correct |
111 |
Correct |
40 ms |
1164 KB |
Output is correct |
112 |
Correct |
7 ms |
852 KB |
Output is correct |
113 |
Execution timed out |
2059 ms |
1192 KB |
Time limit exceeded |
114 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
212 KB |
Output is correct |
3 |
Correct |
1 ms |
212 KB |
Output is correct |
4 |
Correct |
1 ms |
212 KB |
Output is correct |
5 |
Correct |
1 ms |
212 KB |
Output is correct |
6 |
Correct |
1 ms |
212 KB |
Output is correct |
7 |
Correct |
1 ms |
340 KB |
Output is correct |
8 |
Correct |
0 ms |
340 KB |
Output is correct |
9 |
Correct |
1 ms |
324 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
0 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
212 KB |
Output is correct |
13 |
Correct |
1 ms |
324 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
340 KB |
Output is correct |
19 |
Correct |
4 ms |
596 KB |
Output is correct |
20 |
Correct |
3 ms |
980 KB |
Output is correct |
21 |
Correct |
4 ms |
852 KB |
Output is correct |
22 |
Correct |
5 ms |
596 KB |
Output is correct |
23 |
Correct |
3 ms |
596 KB |
Output is correct |
24 |
Correct |
5 ms |
1232 KB |
Output is correct |
25 |
Correct |
4 ms |
1236 KB |
Output is correct |
26 |
Correct |
5 ms |
592 KB |
Output is correct |
27 |
Correct |
5 ms |
596 KB |
Output is correct |
28 |
Correct |
4 ms |
596 KB |
Output is correct |
29 |
Correct |
9 ms |
1108 KB |
Output is correct |
30 |
Correct |
5 ms |
956 KB |
Output is correct |
31 |
Correct |
10 ms |
1620 KB |
Output is correct |
32 |
Correct |
12 ms |
1232 KB |
Output is correct |
33 |
Correct |
9 ms |
1108 KB |
Output is correct |
34 |
Correct |
9 ms |
2368 KB |
Output is correct |
35 |
Correct |
9 ms |
2368 KB |
Output is correct |
36 |
Correct |
13 ms |
1236 KB |
Output is correct |
37 |
Correct |
17 ms |
1104 KB |
Output is correct |
38 |
Correct |
8 ms |
1236 KB |
Output is correct |
39 |
Correct |
100 ms |
7868 KB |
Output is correct |
40 |
Correct |
14 ms |
1296 KB |
Output is correct |
41 |
Correct |
12 ms |
2844 KB |
Output is correct |
42 |
Correct |
21 ms |
1420 KB |
Output is correct |
43 |
Correct |
24 ms |
2644 KB |
Output is correct |
44 |
Correct |
60 ms |
5076 KB |
Output is correct |
45 |
Correct |
49 ms |
5684 KB |
Output is correct |
46 |
Correct |
104 ms |
11996 KB |
Output is correct |
47 |
Correct |
117 ms |
8056 KB |
Output is correct |
48 |
Correct |
93 ms |
8844 KB |
Output is correct |
49 |
Correct |
87 ms |
20864 KB |
Output is correct |
50 |
Correct |
75 ms |
20888 KB |
Output is correct |
51 |
Correct |
127 ms |
9296 KB |
Output is correct |
52 |
Correct |
125 ms |
8716 KB |
Output is correct |
53 |
Correct |
86 ms |
8932 KB |
Output is correct |
54 |
Correct |
1 ms |
212 KB |
Output is correct |
55 |
Correct |
1 ms |
212 KB |
Output is correct |
56 |
Correct |
1 ms |
212 KB |
Output is correct |
57 |
Correct |
1 ms |
212 KB |
Output is correct |
58 |
Correct |
1 ms |
212 KB |
Output is correct |
59 |
Correct |
0 ms |
212 KB |
Output is correct |
60 |
Correct |
1 ms |
212 KB |
Output is correct |
61 |
Correct |
1 ms |
324 KB |
Output is correct |
62 |
Correct |
1 ms |
340 KB |
Output is correct |
63 |
Correct |
1 ms |
212 KB |
Output is correct |
64 |
Correct |
1 ms |
212 KB |
Output is correct |
65 |
Correct |
23 ms |
340 KB |
Output is correct |
66 |
Correct |
10 ms |
340 KB |
Output is correct |
67 |
Correct |
11 ms |
344 KB |
Output is correct |
68 |
Correct |
1 ms |
340 KB |
Output is correct |
69 |
Correct |
1 ms |
340 KB |
Output is correct |
70 |
Correct |
1 ms |
340 KB |
Output is correct |
71 |
Correct |
1 ms |
212 KB |
Output is correct |
72 |
Correct |
1 ms |
212 KB |
Output is correct |
73 |
Correct |
1 ms |
212 KB |
Output is correct |
74 |
Correct |
1 ms |
212 KB |
Output is correct |
75 |
Correct |
1 ms |
212 KB |
Output is correct |
76 |
Correct |
1 ms |
224 KB |
Output is correct |
77 |
Correct |
0 ms |
212 KB |
Output is correct |
78 |
Correct |
0 ms |
212 KB |
Output is correct |
79 |
Correct |
1 ms |
212 KB |
Output is correct |
80 |
Correct |
1 ms |
212 KB |
Output is correct |
81 |
Correct |
1 ms |
328 KB |
Output is correct |
82 |
Correct |
1 ms |
212 KB |
Output is correct |
83 |
Correct |
1 ms |
340 KB |
Output is correct |
84 |
Correct |
1 ms |
340 KB |
Output is correct |
85 |
Correct |
1 ms |
340 KB |
Output is correct |
86 |
Correct |
0 ms |
212 KB |
Output is correct |
87 |
Correct |
0 ms |
212 KB |
Output is correct |
88 |
Correct |
1 ms |
212 KB |
Output is correct |
89 |
Correct |
0 ms |
212 KB |
Output is correct |
90 |
Correct |
1 ms |
212 KB |
Output is correct |
91 |
Correct |
1 ms |
212 KB |
Output is correct |
92 |
Correct |
1 ms |
212 KB |
Output is correct |
93 |
Correct |
1 ms |
212 KB |
Output is correct |
94 |
Correct |
19 ms |
340 KB |
Output is correct |
95 |
Correct |
10 ms |
348 KB |
Output is correct |
96 |
Correct |
10 ms |
340 KB |
Output is correct |
97 |
Correct |
1 ms |
340 KB |
Output is correct |
98 |
Correct |
1 ms |
212 KB |
Output is correct |
99 |
Correct |
1 ms |
212 KB |
Output is correct |
100 |
Correct |
1 ms |
332 KB |
Output is correct |
101 |
Correct |
1 ms |
212 KB |
Output is correct |
102 |
Correct |
1 ms |
328 KB |
Output is correct |
103 |
Correct |
1 ms |
212 KB |
Output is correct |
104 |
Correct |
1 ms |
212 KB |
Output is correct |
105 |
Correct |
1 ms |
212 KB |
Output is correct |
106 |
Correct |
1 ms |
212 KB |
Output is correct |
107 |
Correct |
1 ms |
340 KB |
Output is correct |
108 |
Correct |
1 ms |
340 KB |
Output is correct |
109 |
Correct |
15 ms |
360 KB |
Output is correct |
110 |
Correct |
8 ms |
560 KB |
Output is correct |
111 |
Correct |
40 ms |
1164 KB |
Output is correct |
112 |
Correct |
7 ms |
852 KB |
Output is correct |
113 |
Execution timed out |
2059 ms |
1192 KB |
Time limit exceeded |
114 |
Halted |
0 ms |
0 KB |
- |