답안 #746350

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
746350 2023-05-22T11:39:36 Z ThMinh_ Maze (JOI23_ho_t3) C++14
59 / 100
445 ms 245184 KB
#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;
            bool ok = 0;
            ok |= (s[u1][v1] == '.');
            ok |= (f[u1][v1] == dp);
            if(!ok) 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);
        }
        int a, b; tie(a, b) = q.front(); q.pop();
        vis[a][b] = 1;
        forin(i,-n,n) forin(j,-n,n) if(!(abs(i) == n && abs(j) == n) && check(a + i, b + j)) up(a + i, b + j);
        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.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[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));
            }
        }
        if(f[u][v]) return cout<<f[u][v] - 1, 0;
    }
}

Compilation message

Main.cpp: In function 'int main()':
Main.cpp:57:16: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
   57 |         freopen("Task.inp","r",stdin);
      |         ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
Main.cpp:58:16: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
   58 |         freopen("WA.out","w",stdout);
      |         ~~~~~~~^~~~~~~~~~~~~~~~~~~~~
# 결과 실행 시간 메모리 Grader output
1 Correct 82 ms 188108 KB Output is correct
2 Correct 85 ms 188140 KB Output is correct
3 Correct 83 ms 188088 KB Output is correct
4 Correct 95 ms 188108 KB Output is correct
5 Correct 88 ms 188176 KB Output is correct
6 Correct 87 ms 188080 KB Output is correct
7 Correct 84 ms 188176 KB Output is correct
8 Correct 85 ms 188212 KB Output is correct
9 Correct 89 ms 188072 KB Output is correct
10 Correct 83 ms 188132 KB Output is correct
11 Correct 83 ms 188180 KB Output is correct
12 Correct 86 ms 188104 KB Output is correct
13 Correct 85 ms 188108 KB Output is correct
14 Correct 87 ms 188144 KB Output is correct
15 Correct 96 ms 188168 KB Output is correct
16 Correct 84 ms 188136 KB Output is correct
17 Correct 97 ms 188324 KB Output is correct
18 Correct 85 ms 188200 KB Output is correct
19 Correct 94 ms 189456 KB Output is correct
20 Correct 94 ms 190076 KB Output is correct
21 Correct 91 ms 190412 KB Output is correct
22 Correct 94 ms 189516 KB Output is correct
23 Correct 97 ms 189516 KB Output is correct
24 Correct 97 ms 190684 KB Output is correct
25 Correct 92 ms 190712 KB Output is correct
26 Correct 84 ms 189568 KB Output is correct
27 Correct 108 ms 189432 KB Output is correct
28 Correct 89 ms 189476 KB Output is correct
29 Correct 117 ms 191388 KB Output is correct
30 Correct 94 ms 190000 KB Output is correct
31 Correct 112 ms 193788 KB Output is correct
32 Correct 118 ms 191436 KB Output is correct
33 Correct 112 ms 191432 KB Output is correct
34 Correct 106 ms 194372 KB Output is correct
35 Correct 106 ms 194340 KB Output is correct
36 Correct 101 ms 191680 KB Output is correct
37 Correct 128 ms 191444 KB Output is correct
38 Correct 91 ms 191396 KB Output is correct
39 Correct 445 ms 219924 KB Output is correct
40 Correct 108 ms 191864 KB Output is correct
41 Correct 94 ms 195712 KB Output is correct
42 Correct 141 ms 192684 KB Output is correct
43 Correct 135 ms 195776 KB Output is correct
44 Incorrect 154 ms 206176 KB Output isn't correct
45 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 84 ms 188128 KB Output is correct
2 Correct 89 ms 188048 KB Output is correct
3 Correct 87 ms 188112 KB Output is correct
4 Correct 83 ms 188056 KB Output is correct
5 Correct 86 ms 188108 KB Output is correct
6 Correct 90 ms 188140 KB Output is correct
7 Correct 85 ms 188064 KB Output is correct
8 Correct 82 ms 188124 KB Output is correct
9 Correct 82 ms 188208 KB Output is correct
10 Correct 82 ms 188216 KB Output is correct
11 Correct 88 ms 188092 KB Output is correct
12 Correct 95 ms 188152 KB Output is correct
13 Correct 90 ms 188172 KB Output is correct
14 Correct 88 ms 188192 KB Output is correct
15 Correct 97 ms 188220 KB Output is correct
16 Correct 92 ms 188168 KB Output is correct
17 Correct 87 ms 188204 KB Output is correct
18 Correct 96 ms 188180 KB Output is correct
19 Correct 91 ms 188112 KB Output is correct
20 Correct 109 ms 188052 KB Output is correct
21 Correct 85 ms 188068 KB Output is correct
22 Correct 88 ms 188148 KB Output is correct
23 Correct 86 ms 188168 KB Output is correct
24 Correct 89 ms 188168 KB Output is correct
25 Correct 84 ms 188108 KB Output is correct
26 Correct 84 ms 188172 KB Output is correct
27 Correct 100 ms 188068 KB Output is correct
28 Correct 87 ms 188108 KB Output is correct
29 Correct 88 ms 188100 KB Output is correct
30 Correct 86 ms 188252 KB Output is correct
31 Correct 85 ms 188108 KB Output is correct
32 Correct 89 ms 188112 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 93 ms 188088 KB Output is correct
2 Correct 84 ms 188236 KB Output is correct
3 Correct 88 ms 188108 KB Output is correct
4 Correct 89 ms 188052 KB Output is correct
5 Correct 100 ms 188164 KB Output is correct
6 Correct 86 ms 188108 KB Output is correct
7 Correct 86 ms 188216 KB Output is correct
8 Correct 88 ms 188168 KB Output is correct
9 Correct 84 ms 188132 KB Output is correct
10 Correct 86 ms 188168 KB Output is correct
11 Correct 85 ms 188160 KB Output is correct
12 Correct 92 ms 188172 KB Output is correct
13 Correct 106 ms 188128 KB Output is correct
14 Correct 91 ms 188140 KB Output is correct
15 Correct 83 ms 188080 KB Output is correct
16 Correct 84 ms 188108 KB Output is correct
17 Correct 85 ms 188180 KB Output is correct
18 Correct 86 ms 188104 KB Output is correct
19 Correct 90 ms 188172 KB Output is correct
20 Correct 92 ms 188160 KB Output is correct
21 Correct 86 ms 188192 KB Output is correct
22 Correct 92 ms 188108 KB Output is correct
23 Correct 84 ms 188116 KB Output is correct
24 Correct 89 ms 188212 KB Output is correct
25 Correct 88 ms 189004 KB Output is correct
26 Correct 94 ms 189988 KB Output is correct
27 Correct 105 ms 190472 KB Output is correct
28 Correct 95 ms 190488 KB Output is correct
29 Correct 89 ms 190012 KB Output is correct
30 Correct 90 ms 189972 KB Output is correct
31 Correct 92 ms 189544 KB Output is correct
32 Correct 93 ms 189504 KB Output is correct
33 Correct 90 ms 189460 KB Output is correct
34 Correct 111 ms 192288 KB Output is correct
35 Correct 140 ms 193864 KB Output is correct
36 Correct 108 ms 193928 KB Output is correct
37 Correct 90 ms 192676 KB Output is correct
38 Correct 91 ms 192704 KB Output is correct
39 Correct 186 ms 202776 KB Output is correct
40 Correct 311 ms 230928 KB Output is correct
41 Correct 430 ms 245184 KB Output is correct
42 Correct 355 ms 245088 KB Output is correct
43 Correct 143 ms 233076 KB Output is correct
44 Correct 134 ms 233144 KB Output is correct
45 Correct 324 ms 235712 KB Output is correct
46 Correct 313 ms 235840 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 84 ms 188128 KB Output is correct
2 Correct 89 ms 188048 KB Output is correct
3 Correct 87 ms 188112 KB Output is correct
4 Correct 83 ms 188056 KB Output is correct
5 Correct 86 ms 188108 KB Output is correct
6 Correct 90 ms 188140 KB Output is correct
7 Correct 85 ms 188064 KB Output is correct
8 Correct 82 ms 188124 KB Output is correct
9 Correct 82 ms 188208 KB Output is correct
10 Correct 82 ms 188216 KB Output is correct
11 Correct 88 ms 188092 KB Output is correct
12 Correct 95 ms 188152 KB Output is correct
13 Correct 90 ms 188172 KB Output is correct
14 Correct 88 ms 188192 KB Output is correct
15 Correct 97 ms 188220 KB Output is correct
16 Correct 92 ms 188168 KB Output is correct
17 Correct 87 ms 188204 KB Output is correct
18 Correct 96 ms 188180 KB Output is correct
19 Correct 91 ms 188112 KB Output is correct
20 Correct 109 ms 188052 KB Output is correct
21 Correct 85 ms 188068 KB Output is correct
22 Correct 88 ms 188148 KB Output is correct
23 Correct 86 ms 188168 KB Output is correct
24 Correct 89 ms 188168 KB Output is correct
25 Correct 84 ms 188108 KB Output is correct
26 Correct 84 ms 188172 KB Output is correct
27 Correct 100 ms 188068 KB Output is correct
28 Correct 87 ms 188108 KB Output is correct
29 Correct 88 ms 188100 KB Output is correct
30 Correct 86 ms 188252 KB Output is correct
31 Correct 85 ms 188108 KB Output is correct
32 Correct 89 ms 188112 KB Output is correct
33 Correct 112 ms 189408 KB Output is correct
34 Correct 95 ms 188152 KB Output is correct
35 Correct 86 ms 188288 KB Output is correct
36 Correct 87 ms 189028 KB Output is correct
37 Correct 93 ms 190044 KB Output is correct
38 Correct 120 ms 190008 KB Output is correct
39 Correct 96 ms 190476 KB Output is correct
40 Correct 102 ms 189536 KB Output is correct
41 Correct 97 ms 189464 KB Output is correct
42 Correct 98 ms 190508 KB Output is correct
43 Correct 85 ms 189900 KB Output is correct
44 Correct 91 ms 189900 KB Output is correct
45 Correct 94 ms 190856 KB Output is correct
46 Correct 92 ms 190772 KB Output is correct
47 Correct 121 ms 189968 KB Output is correct
48 Correct 105 ms 189504 KB Output is correct
49 Correct 94 ms 189432 KB Output is correct
50 Correct 96 ms 189536 KB Output is correct
51 Correct 87 ms 189604 KB Output is correct
52 Correct 86 ms 189572 KB Output is correct
53 Correct 82 ms 189464 KB Output is correct
54 Correct 105 ms 189448 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 84 ms 188128 KB Output is correct
2 Correct 89 ms 188048 KB Output is correct
3 Correct 87 ms 188112 KB Output is correct
4 Correct 83 ms 188056 KB Output is correct
5 Correct 86 ms 188108 KB Output is correct
6 Correct 90 ms 188140 KB Output is correct
7 Correct 85 ms 188064 KB Output is correct
8 Correct 82 ms 188124 KB Output is correct
9 Correct 82 ms 188208 KB Output is correct
10 Correct 82 ms 188216 KB Output is correct
11 Correct 88 ms 188092 KB Output is correct
12 Correct 95 ms 188152 KB Output is correct
13 Correct 90 ms 188172 KB Output is correct
14 Correct 88 ms 188192 KB Output is correct
15 Correct 97 ms 188220 KB Output is correct
16 Correct 92 ms 188168 KB Output is correct
17 Correct 87 ms 188204 KB Output is correct
18 Correct 96 ms 188180 KB Output is correct
19 Correct 91 ms 188112 KB Output is correct
20 Correct 109 ms 188052 KB Output is correct
21 Correct 85 ms 188068 KB Output is correct
22 Correct 88 ms 188148 KB Output is correct
23 Correct 86 ms 188168 KB Output is correct
24 Correct 89 ms 188168 KB Output is correct
25 Correct 84 ms 188108 KB Output is correct
26 Correct 84 ms 188172 KB Output is correct
27 Correct 100 ms 188068 KB Output is correct
28 Correct 87 ms 188108 KB Output is correct
29 Correct 88 ms 188100 KB Output is correct
30 Correct 86 ms 188252 KB Output is correct
31 Correct 85 ms 188108 KB Output is correct
32 Correct 89 ms 188112 KB Output is correct
33 Correct 112 ms 189408 KB Output is correct
34 Correct 95 ms 188152 KB Output is correct
35 Correct 86 ms 188288 KB Output is correct
36 Correct 87 ms 189028 KB Output is correct
37 Correct 93 ms 190044 KB Output is correct
38 Correct 120 ms 190008 KB Output is correct
39 Correct 96 ms 190476 KB Output is correct
40 Correct 102 ms 189536 KB Output is correct
41 Correct 97 ms 189464 KB Output is correct
42 Correct 98 ms 190508 KB Output is correct
43 Correct 85 ms 189900 KB Output is correct
44 Correct 91 ms 189900 KB Output is correct
45 Correct 94 ms 190856 KB Output is correct
46 Correct 92 ms 190772 KB Output is correct
47 Correct 121 ms 189968 KB Output is correct
48 Correct 105 ms 189504 KB Output is correct
49 Correct 94 ms 189432 KB Output is correct
50 Correct 96 ms 189536 KB Output is correct
51 Correct 87 ms 189604 KB Output is correct
52 Correct 86 ms 189572 KB Output is correct
53 Correct 82 ms 189464 KB Output is correct
54 Correct 105 ms 189448 KB Output is correct
55 Correct 121 ms 191420 KB Output is correct
56 Correct 90 ms 190028 KB Output is correct
57 Correct 102 ms 192200 KB Output is correct
58 Correct 102 ms 191256 KB Output is correct
59 Correct 108 ms 193820 KB Output is correct
60 Correct 128 ms 191612 KB Output is correct
61 Correct 120 ms 191440 KB Output is correct
62 Correct 112 ms 193940 KB Output is correct
63 Correct 90 ms 192608 KB Output is correct
64 Correct 95 ms 192624 KB Output is correct
65 Correct 103 ms 194456 KB Output is correct
66 Correct 106 ms 194444 KB Output is correct
67 Correct 108 ms 192992 KB Output is correct
68 Correct 110 ms 191560 KB Output is correct
69 Correct 126 ms 191560 KB Output is correct
70 Correct 104 ms 191564 KB Output is correct
71 Correct 108 ms 191648 KB Output is correct
72 Correct 101 ms 191668 KB Output is correct
73 Correct 110 ms 191584 KB Output is correct
74 Correct 84 ms 191524 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 82 ms 188108 KB Output is correct
2 Correct 85 ms 188140 KB Output is correct
3 Correct 83 ms 188088 KB Output is correct
4 Correct 95 ms 188108 KB Output is correct
5 Correct 88 ms 188176 KB Output is correct
6 Correct 87 ms 188080 KB Output is correct
7 Correct 84 ms 188176 KB Output is correct
8 Correct 85 ms 188212 KB Output is correct
9 Correct 89 ms 188072 KB Output is correct
10 Correct 83 ms 188132 KB Output is correct
11 Correct 83 ms 188180 KB Output is correct
12 Correct 86 ms 188104 KB Output is correct
13 Correct 85 ms 188108 KB Output is correct
14 Correct 87 ms 188144 KB Output is correct
15 Correct 96 ms 188168 KB Output is correct
16 Correct 84 ms 188136 KB Output is correct
17 Correct 97 ms 188324 KB Output is correct
18 Correct 85 ms 188200 KB Output is correct
19 Correct 94 ms 189456 KB Output is correct
20 Correct 94 ms 190076 KB Output is correct
21 Correct 91 ms 190412 KB Output is correct
22 Correct 94 ms 189516 KB Output is correct
23 Correct 97 ms 189516 KB Output is correct
24 Correct 97 ms 190684 KB Output is correct
25 Correct 92 ms 190712 KB Output is correct
26 Correct 84 ms 189568 KB Output is correct
27 Correct 108 ms 189432 KB Output is correct
28 Correct 89 ms 189476 KB Output is correct
29 Correct 117 ms 191388 KB Output is correct
30 Correct 94 ms 190000 KB Output is correct
31 Correct 112 ms 193788 KB Output is correct
32 Correct 118 ms 191436 KB Output is correct
33 Correct 112 ms 191432 KB Output is correct
34 Correct 106 ms 194372 KB Output is correct
35 Correct 106 ms 194340 KB Output is correct
36 Correct 101 ms 191680 KB Output is correct
37 Correct 128 ms 191444 KB Output is correct
38 Correct 91 ms 191396 KB Output is correct
39 Correct 445 ms 219924 KB Output is correct
40 Correct 108 ms 191864 KB Output is correct
41 Correct 94 ms 195712 KB Output is correct
42 Correct 141 ms 192684 KB Output is correct
43 Correct 135 ms 195776 KB Output is correct
44 Incorrect 154 ms 206176 KB Output isn't correct
45 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 82 ms 188108 KB Output is correct
2 Correct 85 ms 188140 KB Output is correct
3 Correct 83 ms 188088 KB Output is correct
4 Correct 95 ms 188108 KB Output is correct
5 Correct 88 ms 188176 KB Output is correct
6 Correct 87 ms 188080 KB Output is correct
7 Correct 84 ms 188176 KB Output is correct
8 Correct 85 ms 188212 KB Output is correct
9 Correct 89 ms 188072 KB Output is correct
10 Correct 83 ms 188132 KB Output is correct
11 Correct 83 ms 188180 KB Output is correct
12 Correct 86 ms 188104 KB Output is correct
13 Correct 85 ms 188108 KB Output is correct
14 Correct 87 ms 188144 KB Output is correct
15 Correct 96 ms 188168 KB Output is correct
16 Correct 84 ms 188136 KB Output is correct
17 Correct 97 ms 188324 KB Output is correct
18 Correct 85 ms 188200 KB Output is correct
19 Correct 94 ms 189456 KB Output is correct
20 Correct 94 ms 190076 KB Output is correct
21 Correct 91 ms 190412 KB Output is correct
22 Correct 94 ms 189516 KB Output is correct
23 Correct 97 ms 189516 KB Output is correct
24 Correct 97 ms 190684 KB Output is correct
25 Correct 92 ms 190712 KB Output is correct
26 Correct 84 ms 189568 KB Output is correct
27 Correct 108 ms 189432 KB Output is correct
28 Correct 89 ms 189476 KB Output is correct
29 Correct 117 ms 191388 KB Output is correct
30 Correct 94 ms 190000 KB Output is correct
31 Correct 112 ms 193788 KB Output is correct
32 Correct 118 ms 191436 KB Output is correct
33 Correct 112 ms 191432 KB Output is correct
34 Correct 106 ms 194372 KB Output is correct
35 Correct 106 ms 194340 KB Output is correct
36 Correct 101 ms 191680 KB Output is correct
37 Correct 128 ms 191444 KB Output is correct
38 Correct 91 ms 191396 KB Output is correct
39 Correct 445 ms 219924 KB Output is correct
40 Correct 108 ms 191864 KB Output is correct
41 Correct 94 ms 195712 KB Output is correct
42 Correct 141 ms 192684 KB Output is correct
43 Correct 135 ms 195776 KB Output is correct
44 Incorrect 154 ms 206176 KB Output isn't correct
45 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 82 ms 188108 KB Output is correct
2 Correct 85 ms 188140 KB Output is correct
3 Correct 83 ms 188088 KB Output is correct
4 Correct 95 ms 188108 KB Output is correct
5 Correct 88 ms 188176 KB Output is correct
6 Correct 87 ms 188080 KB Output is correct
7 Correct 84 ms 188176 KB Output is correct
8 Correct 85 ms 188212 KB Output is correct
9 Correct 89 ms 188072 KB Output is correct
10 Correct 83 ms 188132 KB Output is correct
11 Correct 83 ms 188180 KB Output is correct
12 Correct 86 ms 188104 KB Output is correct
13 Correct 85 ms 188108 KB Output is correct
14 Correct 87 ms 188144 KB Output is correct
15 Correct 96 ms 188168 KB Output is correct
16 Correct 84 ms 188136 KB Output is correct
17 Correct 97 ms 188324 KB Output is correct
18 Correct 85 ms 188200 KB Output is correct
19 Correct 94 ms 189456 KB Output is correct
20 Correct 94 ms 190076 KB Output is correct
21 Correct 91 ms 190412 KB Output is correct
22 Correct 94 ms 189516 KB Output is correct
23 Correct 97 ms 189516 KB Output is correct
24 Correct 97 ms 190684 KB Output is correct
25 Correct 92 ms 190712 KB Output is correct
26 Correct 84 ms 189568 KB Output is correct
27 Correct 108 ms 189432 KB Output is correct
28 Correct 89 ms 189476 KB Output is correct
29 Correct 117 ms 191388 KB Output is correct
30 Correct 94 ms 190000 KB Output is correct
31 Correct 112 ms 193788 KB Output is correct
32 Correct 118 ms 191436 KB Output is correct
33 Correct 112 ms 191432 KB Output is correct
34 Correct 106 ms 194372 KB Output is correct
35 Correct 106 ms 194340 KB Output is correct
36 Correct 101 ms 191680 KB Output is correct
37 Correct 128 ms 191444 KB Output is correct
38 Correct 91 ms 191396 KB Output is correct
39 Correct 445 ms 219924 KB Output is correct
40 Correct 108 ms 191864 KB Output is correct
41 Correct 94 ms 195712 KB Output is correct
42 Correct 141 ms 192684 KB Output is correct
43 Correct 135 ms 195776 KB Output is correct
44 Incorrect 154 ms 206176 KB Output isn't correct
45 Halted 0 ms 0 KB -