답안 #1074103

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
1074103 2024-08-25T08:00:03 Z 8e7 Tricolor Lights (JOI24_tricolor) C++17
76 / 100
118 ms 26988 KB
#include "Anna.h"
#include <bits/stdc++.h>
using namespace std;
namespace{
#ifdef zisk
void debug(){cout << endl;}
template<class T, class ... U> void debug(T a, U ... b){cout << a << " ", debug(b...);}
template<class T> void pary(T l, T r) {
	while (l != r) cout << *l << " ", l++;
	cout << endl;
}
#else
#define debug(...) 0
#define pary(...) 0
#endif
#define ll long long
#define maxn 200005
#define pii pair<int, int>
#define ff first
#define ss second
#define io ios_base::sync_with_stdio(0);cin.tie(0);


ll po(ll a, ll n) {
    ll ret = 1;
    while (n) {
        if (n & 1) ret = ret * a;
        n >>= 1;
        a = a * a;
    }
    return ret;
}
vector<int> adj[200000];
vector<int> build_path() {
    int n = 10;
    auto good = [&] (ll x) {
        for (int i = 0;i < n;i++) {
            if (x % 3 == 0) return true;
            x /= 3;
        }
        return false;
    };
    ll m = po(3, n);
    for (int i = 0;i < m;i++) {
        for (int j = 0;j < 3;j++) {
            int to = (i * 3 + j) % m;
            if (!good(i) && j != 0) continue;
            if (i == 0 && j == 0) continue;
            adj[i].push_back(to); 
        }
    } 
    vector<int> path, stk;
    int cur = 0;
    stk.push_back(cur);
    while (stk.size()) {
        cur = stk.back();
        int tmp = cur;
        while (adj[cur].size()) {
            int v = adj[cur].back();
            adj[cur].pop_back();
            cur = v;
            stk.push_back(v);
            break;
        }        
        if (tmp != cur) continue;
        path.push_back(cur);
        stk.pop_back();
    }
    reverse(path.begin(), path.end());
    return path;
}

int to_int(char c) {
    if (c == 'R') return 0;
    else if (c == 'G') return 1;
    else return 2;
}

char to_char(int i) {
    const string S = "RGB";
    return S[i];
}

int add_diff(int prv, int res) {
    if ((prv+1)%3 != res) return (prv+1)%3;
    else return (prv+2)%3;
}
void add_bit(std::vector<int> &ret, std::vector<int> &v, int bit) {
    //add semantic bit, could be 0/1/2, which takes up v[ind] and v[ind+1]
    int ind = ret.size();
    if (ind >= v.size()) return;
    if (ind + 1 >= v.size()) {
        ret.push_back(add_diff(ret.back(), v[ind]));
        return;
    }
    int done = 0;
    for (int i = 1;i < 3;i++) {
        for (int j = 1;j < 3;j++) {
            int vi = (v[ind] + i) % 3, vj = (v[ind+1] + j) % 3;
            if ((vj - vi + 3) % 3 == bit) {
                ret.push_back(vi);
                ret.push_back(vj);
                done = 1;
                break;
            }
        }
        if (done) break;
    } 
    ind = ret.size();
    if (ind >= v.size()) return;
    ret.push_back(add_diff(ret.back(), v[ind]));
}
}

pair<string, int> anna(int N, string S) {
    vector<int> v(N, 0), ret;
    for (int i = 0;i < N;i++) v[i] = to_int(S[i]);
    ret.push_back((v[0] + 1) %3);
    vector<int> nodes = build_path(); 
    vector<int> dig;
    for (int i = 0;i < 10;i++) add_bit(ret, v, 0), dig.push_back(0);
    for (int i = 1;i < nodes.size();i++) {
        if (ret.size() >= N) break;
        add_bit(ret, v, nodes[i] % 3);
        dig.push_back(nodes[i] % 3);
    } 
    pary(dig.begin(), dig.end());
    while (ret.size() >= N) ret.pop_back(); 
    
    int L = min(N, 34);
    string T;
    for (int i = 0;i < N;i++) T.push_back(to_char(ret[i]));
    return make_pair(T, L);
}
#include "Bruno.h"
#include <bits/stdc++.h>
using namespace std;
namespace{
#ifdef zisk
void debug(){cout << endl;}
template<class T, class ... U> void debug(T a, U ... b){cout << a << " ", debug(b...);}
template<class T> void pary(T l, T r) {
	while (l != r) cout << *l << " ", l++;
	cout << endl;
}
#else
#define debug(...) 0
#define pary(...) 0
#endif
#define ll long long
#define maxn 500005
#define pii pair<int, int>
#define ff first
#define ss second
#define io ios_base::sync_with_stdio(0);cin.tie(0);
int N, L;
ll po(ll a, ll n) {
    ll ret = 1;
    while (n) {
        if (n & 1) ret = ret * a;
        n >>= 1;
        a = a * a;
    }
    return ret;
}
vector<int> adj[200000];
vector<int> build_path() {
    int n = 10;
    auto good = [&] (ll x) {
        for (int i = 0;i < n;i++) {
            if (x % 3 == 0) return true;
            x /= 3;
        }
        return false;
    };
    ll m = po(3, n);
    for (int i = 0;i < m;i++) {
        for (int j = 0;j < 3;j++) {
            int to = (i * 3 + j) % m;
            if (!good(i) && j != 0) continue;
            if (i == 0 && j == 0) continue;
            adj[i].push_back(to); 
        }
    } 
    vector<int> path, stk;
    int cur = 0;
    stk.push_back(cur);
    while (stk.size()) {
        cur = stk.back();
        int tmp = cur;
        while (adj[cur].size()) {
            int v = adj[cur].back();
            adj[cur].pop_back();
            cur = v;
            stk.push_back(v);
            break;
        }        
        if (tmp != cur) continue;
        path.push_back(cur);
        stk.pop_back();
    }
    reverse(path.begin(), path.end());
    return path;
}
vector<int> path;
int edge_ind[maxn];

int to_int(char c) {
    if (c == 'R') return 0;
    else if (c == 'G') return 1;
    else return 2;
}
}

void init(int N, int l) {
    ::N = N;
    ::L = l;
    debug("L", l);
    path = build_path();
    for (int i = 1;i < path.size();i++) {
        int val = path[i-1] * 3 + path[i] % 3; 
        assert(edge_ind[val] == 0);
        edge_ind[val] = i;
    }
}

int bruno(string s) {
    if (N == L) return 1;
    assert(s.size() == L);
    vector<int> v[3];
    bool has_zero[3] = {0, 0, 0};
    for (int i = 1;i < L;i++) {
        int a = to_int(s[i]), b = to_int(s[i-1]);
        v[i%3].push_back((a - b + 3) % 3);
        if (a == b) has_zero[i%3] = 1;
    }
    int col = 0;
    for (int i = 0;i < 3;i++) {
        if (has_zero[i] && !has_zero[(i+1)%3]) col = i;
    } 

    assert(has_zero[0] || has_zero[1] || has_zero[2]);
    assert(!has_zero[0] || !has_zero[1] || !has_zero[2]);
    int num = 0;
    for (int i:v[col]) {
        num = num * 3 + i; 
    }
    int pos = -1 + 3 * edge_ind[num]; 
    pos += 1 - col;
    if (col == 0) pos -= 3;
    debug(num, edge_ind[num], col, pos);
    //debug(num, col);
    
    debug("Answer", pos);
    return pos;
}

Compilation message

Anna.cpp: In function 'void {anonymous}::add_bit(std::vector<int>&, std::vector<int>&, int)':
Anna.cpp:91:13: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   91 |     if (ind >= v.size()) return;
      |         ~~~~^~~~~~~~~~~
Anna.cpp:92:17: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   92 |     if (ind + 1 >= v.size()) {
      |         ~~~~~~~~^~~~~~~~~~~
Anna.cpp:110:13: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  110 |     if (ind >= v.size()) return;
      |         ~~~~^~~~~~~~~~~
Anna.cpp: In function 'std::pair<std::__cxx11::basic_string<char>, int> anna(int, std::string)':
Anna.cpp:122:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  122 |     for (int i = 1;i < nodes.size();i++) {
      |                    ~~^~~~~~~~~~~~~~
Anna.cpp:123:24: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
  123 |         if (ret.size() >= N) break;
      |             ~~~~~~~~~~~^~~~
Anna.cpp:14:19: warning: statement has no effect [-Wunused-value]
   14 | #define pary(...) 0
      |                   ^
Anna.cpp:127:5: note: in expansion of macro 'pary'
  127 |     pary(dig.begin(), dig.end());
      |     ^~~~
Anna.cpp:128:23: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
  128 |     while (ret.size() >= N) ret.pop_back();
      |            ~~~~~~~~~~~^~~~

Bruno.cpp: In function 'void init(int, int)':
Bruno.cpp:13:20: warning: statement has no effect [-Wunused-value]
   13 | #define debug(...) 0
      |                    ^
Bruno.cpp:84:5: note: in expansion of macro 'debug'
   84 |     debug("L", l);
      |     ^~~~~
Bruno.cpp:86:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
   86 |     for (int i = 1;i < path.size();i++) {
      |                    ~~^~~~~~~~~~~~~
In file included from /usr/include/c++/10/cassert:44,
                 from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:33,
                 from Bruno.cpp:2:
Bruno.cpp: In function 'int bruno(std::string)':
Bruno.cpp:95:21: warning: comparison of integer expressions of different signedness: 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
   95 |     assert(s.size() == L);
      |            ~~~~~~~~~^~~~
Bruno.cpp:13:20: warning: statement has no effect [-Wunused-value]
   13 | #define debug(...) 0
      |                    ^
Bruno.cpp:117:5: note: in expansion of macro 'debug'
  117 |     debug(num, edge_ind[num], col, pos);
      |     ^~~~~
Bruno.cpp:13:20: warning: statement has no effect [-Wunused-value]
   13 | #define debug(...) 0
      |                    ^
Bruno.cpp:120:5: note: in expansion of macro 'debug'
  120 |     debug("Answer", pos);
      |     ^~~~~
# 결과 실행 시간 메모리 Grader output
1 Correct 48 ms 18848 KB Output is correct
2 Correct 47 ms 18908 KB Output is correct
3 Correct 56 ms 18952 KB Output is correct
4 Correct 49 ms 18872 KB Output is correct
5 Correct 62 ms 18860 KB Output is correct
6 Correct 55 ms 18964 KB Output is correct
7 Correct 68 ms 18968 KB Output is correct
8 Correct 54 ms 18924 KB Output is correct
9 Correct 46 ms 18880 KB Output is correct
10 Correct 52 ms 18940 KB Output is correct
11 Correct 52 ms 18852 KB Output is correct
12 Correct 59 ms 18848 KB Output is correct
13 Correct 54 ms 18860 KB Output is correct
14 Correct 48 ms 18924 KB Output is correct
15 Correct 49 ms 18972 KB Output is correct
16 Correct 49 ms 18960 KB Output is correct
17 Correct 53 ms 18792 KB Output is correct
18 Correct 54 ms 18692 KB Output is correct
19 Correct 60 ms 18892 KB Output is correct
20 Correct 60 ms 18784 KB Output is correct
21 Correct 56 ms 18752 KB Output is correct
22 Correct 58 ms 18752 KB Output is correct
23 Correct 53 ms 18832 KB Output is correct
24 Correct 57 ms 18848 KB Output is correct
25 Correct 57 ms 18828 KB Output is correct
26 Correct 86 ms 18852 KB Output is correct
27 Correct 56 ms 18812 KB Output is correct
28 Correct 54 ms 18844 KB Output is correct
29 Correct 55 ms 18756 KB Output is correct
30 Correct 56 ms 18844 KB Output is correct
31 Correct 56 ms 18816 KB Output is correct
32 Correct 59 ms 18940 KB Output is correct
33 Correct 56 ms 18960 KB Output is correct
34 Correct 60 ms 18628 KB Output is correct
35 Correct 49 ms 18592 KB Output is correct
36 Correct 56 ms 18908 KB Output is correct
37 Correct 56 ms 18848 KB Output is correct
38 Correct 72 ms 18944 KB Output is correct
39 Correct 56 ms 18764 KB Output is correct
40 Correct 83 ms 18908 KB Output is correct
41 Correct 54 ms 18956 KB Output is correct
42 Correct 59 ms 18956 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 48 ms 18848 KB Output is correct
2 Correct 47 ms 18908 KB Output is correct
3 Correct 56 ms 18952 KB Output is correct
4 Correct 49 ms 18872 KB Output is correct
5 Correct 62 ms 18860 KB Output is correct
6 Correct 55 ms 18964 KB Output is correct
7 Correct 68 ms 18968 KB Output is correct
8 Correct 54 ms 18924 KB Output is correct
9 Correct 46 ms 18880 KB Output is correct
10 Correct 52 ms 18940 KB Output is correct
11 Correct 52 ms 18852 KB Output is correct
12 Correct 59 ms 18848 KB Output is correct
13 Correct 54 ms 18860 KB Output is correct
14 Correct 48 ms 18924 KB Output is correct
15 Correct 49 ms 18972 KB Output is correct
16 Correct 49 ms 18960 KB Output is correct
17 Correct 53 ms 18792 KB Output is correct
18 Correct 54 ms 18692 KB Output is correct
19 Correct 60 ms 18892 KB Output is correct
20 Correct 60 ms 18784 KB Output is correct
21 Correct 56 ms 18752 KB Output is correct
22 Correct 58 ms 18752 KB Output is correct
23 Correct 53 ms 18832 KB Output is correct
24 Correct 57 ms 18848 KB Output is correct
25 Correct 57 ms 18828 KB Output is correct
26 Correct 86 ms 18852 KB Output is correct
27 Correct 56 ms 18812 KB Output is correct
28 Correct 54 ms 18844 KB Output is correct
29 Correct 55 ms 18756 KB Output is correct
30 Correct 56 ms 18844 KB Output is correct
31 Correct 56 ms 18816 KB Output is correct
32 Correct 59 ms 18940 KB Output is correct
33 Correct 56 ms 18960 KB Output is correct
34 Correct 60 ms 18628 KB Output is correct
35 Correct 49 ms 18592 KB Output is correct
36 Correct 56 ms 18908 KB Output is correct
37 Correct 56 ms 18848 KB Output is correct
38 Correct 72 ms 18944 KB Output is correct
39 Correct 56 ms 18764 KB Output is correct
40 Correct 83 ms 18908 KB Output is correct
41 Correct 54 ms 18956 KB Output is correct
42 Correct 59 ms 18956 KB Output is correct
43 Correct 55 ms 18716 KB Output is correct
44 Correct 56 ms 18940 KB Output is correct
45 Correct 55 ms 18892 KB Output is correct
46 Correct 56 ms 18768 KB Output is correct
47 Correct 56 ms 18728 KB Output is correct
48 Correct 96 ms 18636 KB Output is correct
49 Correct 56 ms 18904 KB Output is correct
50 Correct 58 ms 18896 KB Output is correct
51 Correct 55 ms 18956 KB Output is correct
52 Correct 61 ms 18728 KB Output is correct
53 Correct 60 ms 18812 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 48 ms 18848 KB Output is correct
2 Correct 47 ms 18908 KB Output is correct
3 Correct 56 ms 18952 KB Output is correct
4 Correct 49 ms 18872 KB Output is correct
5 Correct 62 ms 18860 KB Output is correct
6 Correct 55 ms 18964 KB Output is correct
7 Correct 68 ms 18968 KB Output is correct
8 Correct 54 ms 18924 KB Output is correct
9 Correct 46 ms 18880 KB Output is correct
10 Correct 52 ms 18940 KB Output is correct
11 Correct 52 ms 18852 KB Output is correct
12 Correct 59 ms 18848 KB Output is correct
13 Correct 54 ms 18860 KB Output is correct
14 Correct 48 ms 18924 KB Output is correct
15 Correct 49 ms 18972 KB Output is correct
16 Correct 49 ms 18960 KB Output is correct
17 Correct 53 ms 18792 KB Output is correct
18 Correct 54 ms 18692 KB Output is correct
19 Correct 60 ms 18892 KB Output is correct
20 Correct 60 ms 18784 KB Output is correct
21 Correct 56 ms 18752 KB Output is correct
22 Correct 58 ms 18752 KB Output is correct
23 Correct 53 ms 18832 KB Output is correct
24 Correct 57 ms 18848 KB Output is correct
25 Correct 57 ms 18828 KB Output is correct
26 Correct 86 ms 18852 KB Output is correct
27 Correct 56 ms 18812 KB Output is correct
28 Correct 54 ms 18844 KB Output is correct
29 Correct 55 ms 18756 KB Output is correct
30 Correct 56 ms 18844 KB Output is correct
31 Correct 56 ms 18816 KB Output is correct
32 Correct 59 ms 18940 KB Output is correct
33 Correct 56 ms 18960 KB Output is correct
34 Correct 60 ms 18628 KB Output is correct
35 Correct 49 ms 18592 KB Output is correct
36 Correct 56 ms 18908 KB Output is correct
37 Correct 56 ms 18848 KB Output is correct
38 Correct 72 ms 18944 KB Output is correct
39 Correct 56 ms 18764 KB Output is correct
40 Correct 83 ms 18908 KB Output is correct
41 Correct 54 ms 18956 KB Output is correct
42 Correct 59 ms 18956 KB Output is correct
43 Correct 55 ms 18716 KB Output is correct
44 Correct 56 ms 18940 KB Output is correct
45 Correct 55 ms 18892 KB Output is correct
46 Correct 56 ms 18768 KB Output is correct
47 Correct 56 ms 18728 KB Output is correct
48 Correct 96 ms 18636 KB Output is correct
49 Correct 56 ms 18904 KB Output is correct
50 Correct 58 ms 18896 KB Output is correct
51 Correct 55 ms 18956 KB Output is correct
52 Correct 61 ms 18728 KB Output is correct
53 Correct 60 ms 18812 KB Output is correct
54 Correct 73 ms 18840 KB Output is correct
55 Correct 56 ms 18760 KB Output is correct
56 Correct 58 ms 18900 KB Output is correct
57 Correct 53 ms 18880 KB Output is correct
58 Correct 54 ms 18960 KB Output is correct
59 Correct 54 ms 18844 KB Output is correct
60 Correct 60 ms 18876 KB Output is correct
61 Correct 55 ms 18844 KB Output is correct
62 Correct 53 ms 18880 KB Output is correct
63 Correct 56 ms 18940 KB Output is correct
64 Correct 56 ms 18788 KB Output is correct
65 Correct 53 ms 18916 KB Output is correct
66 Correct 92 ms 19096 KB Output is correct
67 Correct 59 ms 18872 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 48 ms 18848 KB Output is correct
2 Correct 47 ms 18908 KB Output is correct
3 Correct 56 ms 18952 KB Output is correct
4 Correct 49 ms 18872 KB Output is correct
5 Correct 62 ms 18860 KB Output is correct
6 Correct 55 ms 18964 KB Output is correct
7 Correct 68 ms 18968 KB Output is correct
8 Correct 54 ms 18924 KB Output is correct
9 Correct 46 ms 18880 KB Output is correct
10 Correct 52 ms 18940 KB Output is correct
11 Correct 52 ms 18852 KB Output is correct
12 Correct 59 ms 18848 KB Output is correct
13 Correct 54 ms 18860 KB Output is correct
14 Correct 48 ms 18924 KB Output is correct
15 Correct 49 ms 18972 KB Output is correct
16 Correct 49 ms 18960 KB Output is correct
17 Correct 53 ms 18792 KB Output is correct
18 Correct 54 ms 18692 KB Output is correct
19 Correct 60 ms 18892 KB Output is correct
20 Correct 60 ms 18784 KB Output is correct
21 Correct 56 ms 18752 KB Output is correct
22 Correct 58 ms 18752 KB Output is correct
23 Correct 53 ms 18832 KB Output is correct
24 Correct 57 ms 18848 KB Output is correct
25 Correct 57 ms 18828 KB Output is correct
26 Correct 86 ms 18852 KB Output is correct
27 Correct 56 ms 18812 KB Output is correct
28 Correct 54 ms 18844 KB Output is correct
29 Correct 55 ms 18756 KB Output is correct
30 Correct 56 ms 18844 KB Output is correct
31 Correct 56 ms 18816 KB Output is correct
32 Correct 59 ms 18940 KB Output is correct
33 Correct 56 ms 18960 KB Output is correct
34 Correct 60 ms 18628 KB Output is correct
35 Correct 49 ms 18592 KB Output is correct
36 Correct 56 ms 18908 KB Output is correct
37 Correct 56 ms 18848 KB Output is correct
38 Correct 72 ms 18944 KB Output is correct
39 Correct 56 ms 18764 KB Output is correct
40 Correct 83 ms 18908 KB Output is correct
41 Correct 54 ms 18956 KB Output is correct
42 Correct 59 ms 18956 KB Output is correct
43 Correct 55 ms 18716 KB Output is correct
44 Correct 56 ms 18940 KB Output is correct
45 Correct 55 ms 18892 KB Output is correct
46 Correct 56 ms 18768 KB Output is correct
47 Correct 56 ms 18728 KB Output is correct
48 Correct 96 ms 18636 KB Output is correct
49 Correct 56 ms 18904 KB Output is correct
50 Correct 58 ms 18896 KB Output is correct
51 Correct 55 ms 18956 KB Output is correct
52 Correct 61 ms 18728 KB Output is correct
53 Correct 60 ms 18812 KB Output is correct
54 Correct 73 ms 18840 KB Output is correct
55 Correct 56 ms 18760 KB Output is correct
56 Correct 58 ms 18900 KB Output is correct
57 Correct 53 ms 18880 KB Output is correct
58 Correct 54 ms 18960 KB Output is correct
59 Correct 54 ms 18844 KB Output is correct
60 Correct 60 ms 18876 KB Output is correct
61 Correct 55 ms 18844 KB Output is correct
62 Correct 53 ms 18880 KB Output is correct
63 Correct 56 ms 18940 KB Output is correct
64 Correct 56 ms 18788 KB Output is correct
65 Correct 53 ms 18916 KB Output is correct
66 Correct 92 ms 19096 KB Output is correct
67 Correct 59 ms 18872 KB Output is correct
68 Correct 61 ms 18880 KB Output is correct
69 Correct 57 ms 18848 KB Output is correct
70 Correct 63 ms 18848 KB Output is correct
71 Correct 88 ms 18868 KB Output is correct
72 Correct 61 ms 18848 KB Output is correct
73 Correct 67 ms 18884 KB Output is correct
74 Correct 56 ms 20528 KB Output is correct
75 Correct 60 ms 20456 KB Output is correct
76 Correct 61 ms 20520 KB Output is correct
77 Correct 56 ms 20448 KB Output is correct
78 Correct 57 ms 20708 KB Output is correct
79 Correct 55 ms 20656 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 48 ms 20624 KB Output is correct
2 Correct 67 ms 20612 KB Output is correct
3 Correct 48 ms 20628 KB Output is correct
4 Correct 57 ms 20612 KB Output is correct
5 Partially correct 54 ms 20436 KB Partially correct
6 Partially correct 56 ms 20764 KB Partially correct
7 Partially correct 55 ms 20728 KB Partially correct
8 Partially correct 55 ms 20628 KB Partially correct
9 Partially correct 59 ms 20740 KB Partially correct
10 Partially correct 54 ms 20724 KB Partially correct
11 Partially correct 53 ms 20640 KB Partially correct
12 Partially correct 59 ms 20640 KB Partially correct
13 Partially correct 64 ms 20476 KB Partially correct
14 Partially correct 54 ms 20596 KB Partially correct
15 Partially correct 81 ms 26988 KB Partially correct
16 Partially correct 80 ms 26980 KB Partially correct
17 Partially correct 81 ms 26980 KB Partially correct
18 Correct 55 ms 20728 KB Output is correct
19 Correct 51 ms 20724 KB Output is correct
20 Correct 55 ms 20480 KB Output is correct
21 Correct 54 ms 20704 KB Output is correct
22 Correct 50 ms 20512 KB Output is correct
23 Partially correct 50 ms 20596 KB Partially correct
24 Partially correct 51 ms 20664 KB Partially correct
25 Partially correct 54 ms 20520 KB Partially correct
26 Partially correct 60 ms 20572 KB Partially correct
27 Partially correct 78 ms 20444 KB Partially correct
28 Partially correct 52 ms 20652 KB Partially correct
29 Partially correct 55 ms 20636 KB Partially correct
30 Partially correct 56 ms 20544 KB Partially correct
31 Partially correct 62 ms 20636 KB Partially correct
32 Partially correct 54 ms 20728 KB Partially correct
33 Partially correct 54 ms 20720 KB Partially correct
34 Partially correct 54 ms 20640 KB Partially correct
35 Partially correct 55 ms 20672 KB Partially correct
36 Partially correct 55 ms 20560 KB Partially correct
37 Partially correct 64 ms 20640 KB Partially correct
38 Partially correct 57 ms 20640 KB Partially correct
39 Partially correct 80 ms 20588 KB Partially correct
40 Partially correct 62 ms 20636 KB Partially correct
41 Partially correct 64 ms 20568 KB Partially correct
42 Partially correct 73 ms 20488 KB Partially correct
43 Partially correct 87 ms 20592 KB Partially correct
44 Partially correct 55 ms 20520 KB Partially correct
45 Partially correct 57 ms 20636 KB Partially correct
46 Partially correct 55 ms 20540 KB Partially correct
47 Partially correct 61 ms 20748 KB Partially correct
48 Partially correct 60 ms 20584 KB Partially correct
49 Partially correct 60 ms 20640 KB Partially correct
50 Partially correct 57 ms 20636 KB Partially correct
51 Partially correct 83 ms 20668 KB Partially correct
52 Partially correct 56 ms 20892 KB Partially correct
53 Partially correct 54 ms 20752 KB Partially correct
54 Partially correct 61 ms 21248 KB Partially correct
55 Partially correct 111 ms 26984 KB Partially correct
56 Partially correct 94 ms 26988 KB Partially correct
57 Partially correct 87 ms 25196 KB Partially correct
58 Correct 48 ms 19028 KB Output is correct
59 Correct 48 ms 18908 KB Output is correct
60 Partially correct 55 ms 18792 KB Partially correct
61 Partially correct 57 ms 18844 KB Partially correct
62 Partially correct 82 ms 18748 KB Partially correct
63 Partially correct 55 ms 18776 KB Partially correct
64 Partially correct 55 ms 18844 KB Partially correct
65 Partially correct 56 ms 18688 KB Partially correct
66 Partially correct 60 ms 18832 KB Partially correct
67 Partially correct 56 ms 18912 KB Partially correct
68 Partially correct 54 ms 18960 KB Partially correct
69 Partially correct 79 ms 25076 KB Partially correct
70 Partially correct 79 ms 25188 KB Partially correct
71 Partially correct 118 ms 25188 KB Partially correct
72 Partially correct 54 ms 18736 KB Partially correct
73 Partially correct 74 ms 18844 KB Partially correct
74 Partially correct 61 ms 18684 KB Partially correct
75 Partially correct 55 ms 18728 KB Partially correct
76 Partially correct 70 ms 18704 KB Partially correct
77 Partially correct 61 ms 18848 KB Partially correct
78 Partially correct 87 ms 25060 KB Partially correct
79 Partially correct 89 ms 25188 KB Partially correct
80 Partially correct 100 ms 25188 KB Partially correct
81 Partially correct 56 ms 18852 KB Partially correct
82 Partially correct 80 ms 18892 KB Partially correct
83 Partially correct 66 ms 18716 KB Partially correct
84 Partially correct 56 ms 18968 KB Partially correct
85 Partially correct 57 ms 18876 KB Partially correct
86 Partially correct 65 ms 18844 KB Partially correct
87 Partially correct 54 ms 18784 KB Partially correct
88 Partially correct 61 ms 18844 KB Partially correct
89 Partially correct 61 ms 18844 KB Partially correct
90 Partially correct 54 ms 18884 KB Partially correct
91 Partially correct 85 ms 18896 KB Partially correct
92 Partially correct 56 ms 18788 KB Partially correct
93 Partially correct 113 ms 25188 KB Partially correct
94 Partially correct 81 ms 25188 KB Partially correct
95 Partially correct 108 ms 25196 KB Partially correct