QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#131735#2760. Simurghpandapythoner#51 333ms7344kbC++204.1kb2023-07-27 22:37:272024-07-04 01:00:36

Judging History

你现在查看的是最新测评结果

  • [2024-07-04 01:00:36]
  • 评测
  • 测评结果:51
  • 用时:333ms
  • 内存:7344kb
  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-07-27 22:37:27]
  • 提交

answer

#ifdef LOCAL
#define _GLIBCXX_DEBUG
#endif

#include <bits/stdc++.h>

#include "simurgh.h"

using namespace std;

#define ll long long
#define flt double
#define all(a) a.begin(), a.end()
#define rall(a) a.rbegin(), a.rend()

const ll inf = 1e18;
mt19937 rnd(234);

struct DSU {
    int n;
    vector<int> t;

    void build(int _n) {
        n = _n;
        t.resize(n);
        for (int i = 0; i < n; i += 1) {
            t[i] = i;
        }
    }
};

struct edge {
    int to, i;
};

bool operator==(const edge &a, const edge &b) {
    return a.to == b.to && a.i == b.i;
}

int n, m;
vector<pair<int, int>> edgs;
vector<int> tp;
vector<vector<edge>> g;
vector<int> usd;
vector<int> h;

bool dfs0(int v, int mh, int pri, vector<int> &stck, vector<int> &cycle) {
    h[v] = mh;
    usd[v] = 1;
    for (auto [to, i] : g[v]) {
        if (pri == i) {
            continue;
        }
        if (usd[to] == 1) {
            int dst = mh - h[to];
            cycle = vector<int>(stck.end() - dst, stck.end());
            cycle.push_back(i);
            return true;
        }
        if (usd[to] == 0) {
            stck.push_back(i);
            int x = dfs0(to, mh + 1, i, stck, cycle);
            stck.pop_back();
            if (x) {
                return true;
            }
        }
    }
    usd[v] = 2;
    return false;
}

void find_cycle(vector<int> &cycle) {
    usd.assign(n, 0);
    h.resize(n);
    vector<int> stck;
    stck.reserve(n);
    dfs0(0, 0, -1, stck, cycle);
}

void dfs1(int v, vector<int> &rs) {
    usd[v] = 1;
    for (auto [to, i] : g[v]) {
        if (!usd[to]) {
            rs.push_back(i);
            dfs1(to, rs);
        }
    }
}

vector<int> add_edgs(vector<int> &c) {
    auto rs = c;
    usd.assign(n, 0);
    for (auto i : c) {
        auto [u, v] = edgs[i];
        usd[u] = 1;
        usd[v] = 1;
    }
    for (auto i : c) {
        auto [u, v] = edgs[i];
        if (usd[u] == 1) {
            dfs1(u, rs);
            usd[u] = 2;
        }
        if (usd[v] == 1) {
            dfs1(v, rs);
            usd[v] = 2;
        }
    }
    return rs;
}

void reveal_cycle(vector<int> &c) {
    auto f = add_edgs(c);
    int sz = (int)c.size();
    vector<int> p(sz, -1);
    int mx = 0;
    for (int i = 0; i < sz; i += 1) {
        int j = c[i];
        if (tp[j] == -1) {
            auto nf = f;
            nf.erase(nf.begin() + i);
            p[i] = count_common_roads(nf);
            mx = max(mx, p[i]);
        }
    }
    for (int i = 0; i < sz; i += 1) {
        int j = c[i];
        if (tp[j] == -1) {
            if (p[i] == mx) {
                tp[j] = 0;
            } else {
                tp[j] = 1;
            }
        }
    }
}

void erase(vector<edge> &t, const edge &x) {
    for (int i = 0; i < (int)t.size(); i += 1) {
        if (t[i] == x) {
            t.erase(t.begin() + i);
            break;
        }
    }
}

void delete_edge_from_g(int i) {
    auto [u, v] = edgs[i];
    erase(g[u], edge{v, i});
    erase(g[v], edge{u, i});
}

vector<int> solve_slow() {
    tp.assign(m, -1);
    g.assign(n, vector<edge>());
    for (int i = 0; i < m; i += 1) {
        auto [u, v] = edgs[i];
        g[u].push_back(edge{v, i});
        g[v].push_back(edge{u, i});
    }
    int cnt = m;
    while (cnt > n - 1) {
        vector<int> c;
        find_cycle(c);
        reveal_cycle(c);
        for (auto j : c) {
            if (tp[j] == 0) {
                delete_edge_from_g(j);
                cnt -= 1;
            }
        }
    }
    vector<int> rs;
    for (int v = 0; v < n; v += 1) {
        for (auto [to, i] : g[v]) {
            if (to < v) {
                rs.push_back(i);
            }
        }
    }
    return rs;
}

vector<int> find_roads(int _n, vector<int> _u, vector<int> _v) {
    n = _n;
    m = _u.size();
    edgs.resize(m);
    for (int i = 0; i < m; i += 1) {
        edgs[i] = make_pair(_u[i], _v[i]);
    }
    auto rs = solve_slow();
    return rs;
}

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 13
Accepted

Test #1:

score: 13
Accepted
time: 1ms
memory: 3860kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 21 30000
2 0
0 1
5 2
2 6
1 3
3 0
6 0
4 5
3 2
4 0
1 4
0 5
4 3
4 6
6 1
2 1
5 3
2 4
5 6
5 1
6 3
7 10 9 13 12 17

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
9 10 12 17 7 13

result:

ok correct

Test #2:

score: 13
Accepted
time: 1ms
memory: 3720kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 21 30000
4 6
1 6
2 3
0 3
2 1
2 6
5 6
6 3
0 2
1 0
4 2
1 3
5 2
5 0
0 6
5 3
4 5
5 1
3 4
1 4
4 0
4 16 10 0 20 18

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
4 10 18 20 16 0

result:

ok correct

Test #3:

score: 13
Accepted
time: 0ms
memory: 3772kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 21 30000
2 5
0 4
4 5
4 3
5 3
1 3
3 6
4 1
6 0
5 6
6 2
6 1
6 4
3 2
2 1
1 0
0 2
5 0
5 1
4 2
0 3
20 17 15 9 2 19

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
15 20 19 2 17 9

result:

ok correct

Test #4:

score: 13
Accepted
time: 0ms
memory: 3980kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 13 30000
2 4
4 3
3 2
0 3
0 4
6 3
6 1
4 5
6 2
1 3
5 6
6 0
6 4
3 9 12 7 0 4

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
3 9 0 4 7 12

result:

ok correct

Test #5:

score: 13
Accepted
time: 0ms
memory: 3860kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
6 10 30000
5 2
0 1
1 2
0 3
3 2
1 4
0 5
3 5
4 3
1 3
5 0 7 2 1

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
1 2 5 0 7

result:

ok correct

Test #6:

score: 13
Accepted
time: 1ms
memory: 3724kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 16 30000
3 4
2 5
2 1
0 5
1 5
0 2
2 6
6 1
4 6
0 1
2 3
6 3
3 1
1 4
4 5
3 5
0 9 5 15 3 11

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
9 5 0 3 15 11

result:

ok correct

Test #7:

score: 13
Accepted
time: 0ms
memory: 3852kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
2 1 30000
0 1
0

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
0

result:

ok correct

Test #8:

score: 13
Accepted
time: 0ms
memory: 3752kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
3 3 30000
0 1
2 0
1 2
2 0

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
0 2

result:

ok correct

Test #9:

score: 13
Accepted
time: 1ms
memory: 3788kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
6 5 30000
2 4
5 4
4 0
4 1
3 4
3 1 4 0 2

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
0 2 3 4 1

result:

ok correct

Test #10:

score: 13
Accepted
time: 0ms
memory: 3744kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
6 14 30000
4 2
1 3
4 5
4 1
0 4
0 1
2 3
2 1
0 3
5 3
0 5
0 2
5 2
1 5
13 8 10 7 3

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
7 8 3 10 13

result:

ok correct

Test #11:

score: 13
Accepted
time: 0ms
memory: 3724kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 6 30000
3 0
3 5
4 0
5 6
0 2
1 3
3 4 1 5 0 2

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
4 0 5 2 1 3

result:

ok correct

Test #12:

score: 13
Accepted
time: 1ms
memory: 3936kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
6 15 30000
4 3
2 3
3 5
2 0
5 2
1 3
1 4
0 5
3 0
4 0
1 0
2 1
4 5
4 2
5 1
9 13 12 6 0

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
0 6 9 13 12

result:

ok correct

Test #13:

score: 13
Accepted
time: 1ms
memory: 3796kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
7 21 30000
0 2
2 5
3 4
0 3
5 4
4 2
2 1
4 6
5 3
0 1
4 0
1 6
3 6
1 3
1 5
5 0
0 6
4 1
6 5
3 2
2 6
16 3 18 17 4 6

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
6 3 17 4 16 18

result:

ok correct

Subtask #2:

score: 17
Accepted

Dependency #1:

100%
Accepted

Test #14:

score: 17
Accepted
time: 3ms
memory: 3792kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 1225 30000
47 4
24 48
42 13
5 42
19 17
29 31
23 48
37 25
37 43
27 22
43 30
19 44
49 37
39 14
26 46
46 35
49 15
40 19
6 31
37 1
21 0
26 45
6 4
38 36
6 8
20 4
18 24
20 35
5 29
1 19
35 49
29 20
25 10
10 36
2 22
26 11
7 9
24 3
35 38
48 41
22...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
497 851 24 679 746 257 355 1033 277 1071 923 61 195 440 760 221 638 509 706 166 458 584 299 768 770 119 212 552 478 333 754 322 866 1042 62 503 795 1006 1107 377 860 127 397 1199 848 1205 591 880 1058

result:

ok correct

Test #15:

score: 17
Accepted
time: 2ms
memory: 4088kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 1225 30000
44 29
11 44
39 16
20 31
6 3
9 27
49 27
12 0
27 1
48 49
46 12
35 36
35 11
49 13
23 20
28 26
12 1
42 37
5 15
28 32
6 10
16 7
4 43
4 31
49 34
9 14
2 46
44 30
40 17
14 29
41 18
27 44
13 3
23 40
47 24
16 3
6 26
45 18
24 42
11 10
23...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
48 95 181 275 354 501 577 649 456 297 600 849 67 182 701 21 88 228 89 1173 607 1055 1051 151 178 562 256 97 1185 769 279 472 496 315 280 230 497 913 294 776 552 678 633 723 204 1037 933 420 196

result:

ok correct

Test #16:

score: 17
Accepted
time: 2ms
memory: 3844kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 1225 30000
12 30
6 44
33 47
7 33
0 2
10 30
30 46
14 11
43 42
13 27
49 24
6 17
21 2
12 21
24 38
5 21
17 0
16 4
26 5
27 32
20 45
6 20
19 0
20 35
47 39
17 39
0 23
26 33
1 17
3 20
4 46
48 21
21 35
24 40
9 29
28 23
9 1
43 34
4 44
18 37
40 13
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
166 25 56 67 93 95 150 160 198 204 213 261 273 290 438 466 470 482 513 524 790 795 834 841 847 859 874 882 885 894 907 917 948 997 1048 1064 1068 1075 1082 610 535 222 784 966 374 1141 24 326 382

result:

ok correct

Test #17:

score: 17
Accepted
time: 2ms
memory: 3732kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 1002 30000
35 6
20 23
17 3
16 48
49 29
31 32
38 3
10 39
16 4
47 13
0 19
24 25
42 39
48 44
39 32
1 42
18 8
17 15
19 32
33 23
21 18
7 13
6 0
26 35
34 22
39 13
48 47
6 21
44 7
21 13
43 16
41 43
36 6
25 14
3 49
3 33
47 29
25 45
45 13
12 13
3...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
614 237 174 308 941 213 20 801 370 313 559 828 351 668 898 841 90 420 837 783 808 348 96 116 670 858 401 357 112 560 963 221 403 436 712 304 823 875 28 372 229 440 266 591 135 402 685 4 636

result:

ok correct

Test #18:

score: 17
Accepted
time: 1ms
memory: 4048kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 371 30000
20 0
5 9
13 38
4 3
12 23
20 42
43 12
27 28
1 42
23 42
14 41
39 9
2 9
10 13
14 32
18 30
6 7
32 3
39 38
12 34
33 0
10 41
32 30
15 43
13 6
2 30
20 14
36 21
17 2
0 28
24 29
19 7
25 15
10 48
21 49
31 7
2 44
7 44
28 40
38 17
33 48
18...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
364 16 89 24 62 277 237 0 349 193 224 105 300 121 82 74 294 35 139 14 152 234 45 210 129 238 27 257 18 38 131 21 101 46 216 239 314 102 156 279 344 93 140 135 212 233 274 290 309

result:

ok correct

Test #19:

score: 17
Accepted
time: 2ms
memory: 4004kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 1027 30000
46 5
15 29
43 39
16 32
38 5
4 22
13 4
41 5
0 41
39 6
6 8
3 13
25 6
40 25
17 40
47 0
26 15
30 11
27 31
43 45
30 17
35 37
8 27
2 38
35 19
7 12
36 31
41 21
14 25
14 35
15 17
37 2
27 46
24 39
24 29
19 10
28 1
22 35
24 41
16 46
13 ...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
142 230 406 173 928 1005 986 140 83 5 839 1007 220 607 170 674 585 816 112 488 974 196 85 645 148 31 313 497 983 639 13 521 158 417 487 77 988 571 660 238 398 994 506 885 583 1021 670 1001 198

result:

ok correct

Test #20:

score: 17
Accepted
time: 2ms
memory: 3804kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 965 30000
28 25
38 23
12 44
1 35
45 46
39 4
19 22
40 23
25 49
20 29
30 9
17 2
15 32
32 14
45 7
19 12
40 22
12 35
10 5
49 37
29 31
19 40
22 6
28 46
23 11
2 1
40 24
14 44
44 40
16 47
7 14
38 47
43 34
4 18
17 22
32 30
33 13
36 21
47 37
37 3...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
766 820 161 74 93 114 127 335 508 673 182 952 907 505 125 257 259 6 138 346 799 837 901 352 273 79 541 251 846 50 546 146 841 157 570 109 698 332 48 16 371 911 353 551 544 796 45 679 213

result:

ok correct

Test #21:

score: 17
Accepted
time: 0ms
memory: 3904kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 900 30000
25 47
5 46
35 22
46 22
15 35
37 46
27 46
29 20
0 7
7 14
8 19
28 38
11 7
9 16
28 0
38 29
30 47
23 11
26 10
3 38
30 49
28 13
45 3
7 17
42 0
30 1
48 2
47 22
18 49
26 34
12 20
40 9
12 38
46 16
24 16
40 30
31 33
45 34
16 25
14 31
4 ...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
897 291 745 816 65 40 751 703 300 430 727 805 78 433 551 557 575 763 566 704 877 252 428 288 502 590 870 256 32 498 561 605 645 653 46 360 404 524 530 699 533 27 323 351 487 196 298 423 211

result:

ok correct

Test #22:

score: 17
Accepted
time: 0ms
memory: 3772kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 701 30000
1 47
37 0
2 41
32 33
15 40
38 42
5 27
0 9
0 8
10 36
26 42
5 25
41 35
27 2
21 15
40 28
0 15
43 29
37 3
28 18
9 3
47 27
32 38
48 47
28 13
34 32
27 23
40 8
38 15
46 7
24 14
12 46
47 28
20 43
2 48
2 28
22 45
14 27
23 42
30 35
26 18...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
46 8 7 51 16 61 14 30 11 6 13 26 37 19 24 76 70 3 25 39 9 1 18 22 28 57 4 15 2 12 5 10 17 33 84 56 36 60 86 29 31 55 0 21 32 477 23 42 62

result:

ok correct

Test #23:

score: 17
Accepted
time: 0ms
memory: 3760kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 626 30000
49 25
30 31
0 3
6 11
25 10
19 13
10 49
43 31
7 19
24 28
39 31
15 7
32 30
27 41
18 23
31 13
26 40
19 41
42 30
47 28
5 4
41 24
42 27
15 45
29 14
29 37
42 6
2 42
45 13
27 32
32 20
4 29
4 21
20 24
16 44
14 12
28 6
25 37
10 22
8 48
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
2 20 77 3 35 11 5 8 32 38 49 14 4 56 9 24 31 43 1 15 12 30 97 47 52 25 37 10 66 16 44 13 17 21 18 26 27 7 46 34 23 54 61 51 19 39 41 0 91

result:

ok correct

Test #24:

score: 17
Accepted
time: 2ms
memory: 4056kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 601 30000
28 10
43 16
22 35
42 20
8 39
34 33
47 44
47 49
3 9
10 32
34 5
4 14
9 18
19 33
29 38
31 25
8 2
5 4
5 8
40 23
27 21
36 23
10 6
14 26
39 27
44 36
29 47
6 1
2 46
21 15
43 13
28 38
1 23
41 45
3 49
26 15
39 2
11 17
22 0
45 47
48 46
4...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
17 27 16 18 8 22 65 44 11 37 12 29 38 70 130 23 20 47 0 50 15 9 13 5 10 2 49 21 59 14 31 4 24 19 52 3 60 1 30 25 33 56 28 6 26 39 40 7 34

result:

ok correct

Test #25:

score: 17
Accepted
time: 1ms
memory: 3944kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 85 30000
33 16
22 4
21 25
32 42
13 46
7 38
18 16
38 33
44 27
19 2
3 2
30 24
0 47
49 12
20 47
17 32
23 26
45 28
35 8
31 20
40 34
25 36
25 43
5 40
11 46
24 1
49 35
30 9
17 41
33 29
11 13
28 19
9 32
6 48
11 39
15 23
16 29
31 0
6 38
27 4
3 0...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
10 40 46 47 6 9 82 1 35 44 25 2 16 39 31 11 27 19 15 32 0 29 18 21 45 61 69 5 7 38 34 20 23 28 3 84 22 8 17 70 4 24 12 14 41 33 52 13 26

result:

ok correct

Test #26:

score: 17
Accepted
time: 2ms
memory: 3832kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 602 30000
23 30
14 19
2 28
37 21
18 35
1 24
35 1
2 7
11 14
41 11
15 30
6 47
16 25
27 21
14 31
26 30
36 14
43 8
47 7
1 15
18 14
38 31
16 10
19 45
49 27
40 4
25 13
31 3
43 26
19 39
47 27
30 1
2 27
34 33
43 36
45 18
4 37
39 23
11 17
37 44
2...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
7 42 51 8 19 22 38 20 1 45 5 218 12 26 13 41 2 67 0 10 15 14 27 96 47 33 75 4 6 16 3 36 21 29 40 25 9 71 17 28 39 23 56 44 11 18 30 93 24

result:

ok correct

Test #27:

score: 17
Accepted
time: 2ms
memory: 3780kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 627 30000
2 46
48 6
42 10
35 38
19 24
47 39
37 7
12 39
12 31
6 43
9 5
25 28
12 26
30 16
41 48
45 11
44 31
47 15
31 32
36 37
32 43
36 15
7 48
27 28
26 20
0 6
31 18
45 35
37 3
9 20
5 20
40 2
7 43
35 33
39 15
40 27
0 39
28 42
0 38
17 46
6 7...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
25 10 49 84 93 45 29 4 104 12 24 11 23 53 74 13 8 26 18 48 33 21 6 19 28 3 38 7 31 35 76 2 37 9 20 59 16 15 27 0 39 56 5 17 72 1 14 42 89

result:

ok correct

Test #28:

score: 17
Accepted
time: 1ms
memory: 3752kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 270 30000
20 36
24 11
20 31
45 48
12 16
11 10
36 8
19 31
3 49
6 45
31 33
37 20
41 46
19 33
45 13
44 26
23 20
49 16
40 27
46 45
19 26
33 28
15 25
28 26
43 16
1 31
9 16
19 36
30 9
13 41
0 48
15 49
13 21
28 35
25 49
35 1
47 14
21 41
16 25
1...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
5 43 4 26 87 135 32 217 16 1 22 72 20 65 28 2 7 25 76 10 21 173 51 33 0 6 11 44 56 75 55 18 57 77 24 15 159 9 14 12 19 62 36 86 3 30 8 17 31

result:

ok correct

Test #29:

score: 17
Accepted
time: 1ms
memory: 3740kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 130 30000
26 14
28 25
10 31
20 12
12 39
12 28
41 19
48 5
20 24
27 4
21 43
21 45
11 29
14 46
29 13
36 27
40 11
0 30
32 34
22 30
27 46
6 22
34 40
46 4
13 15
6 49
22 8
49 22
46 36
42 5
45 43
16 32
30 9
26 27
21 37
27 14
2 30
34 23
18 42
21 ...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
24 49 51 65 123 3 21 26 64 8 47 0 9 1 5 12 14 17 19 32 36 43 2 31 48 18 37 45 15 34 54 118 4 16 22 6 29 38 83 10 46 11 70 13 20 39 7 53 25

result:

ok correct

Test #30:

score: 17
Accepted
time: 1ms
memory: 3840kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 625 30000
34 44
19 12
6 24
31 33
30 11
10 40
7 43
46 39
47 4
36 15
8 27
42 21
35 16
26 48
17 29
2 1
0 25
23 14
20 3
32 18
49 13
41 37
22 9
28 38
5 45
17 7
32 0
26 19
19 43
34 45
48 37
48 3
23 37
39 12
22 37
32 49
17 38
19 11
46 26
24 27
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
15 54 25 1 37 18 75 22 17 2 16 27 55 10 39 14 4 42 19 26 3 12 58 9 41 32 34 23 36 40 33 5 21 11 6 28 0 46 64 24 29 7 8 45 13 30 31 20 35

result:

ok correct

Test #31:

score: 17
Accepted
time: 1ms
memory: 3816kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 625 30000
37 43
38 19
3 37
27 46
35 26
15 7
47 34
25 49
2 45
5 20
28 44
11 22
33 1
36 31
16 42
40 32
43 24
6 8
12 14
18 4
9 21
23 48
41 30
13 29
10 0
42 27
20 26
20 9
24 0
32 39
11 10
14 21
11 28
20 46
24 14
18 34
13 18
42 30
43 41
16 9
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
17 24 30 18 5 49 19 36 9 27 20 31 11 28 34 72 26 32 45 52 23 42 40 12 43 35 4 13 2 1 29 15 50 22 14 25 37 0 16 10 8 61 3 33 6 48 21 7 51

result:

ok correct

Test #32:

score: 17
Accepted
time: 2ms
memory: 3764kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 625 30000
25 29
39 24
9 31
10 34
16 41
7 30
46 36
11 27
42 22
18 8
14 20
35 13
5 21
4 26
1 29
0 44
33 43
37 15
38 6
19 32
2 48
23 17
45 40
49 28
47 25
8 35
1 38
4 49
5 14
41 28
16 34
8 41
22 4
44 21
8 37
45 44
14 24
13 32
1 27
31 11
40 0...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
28 9 10 12 32 67 21 62 36 42 13 7 38 0 14 5 2 39 45 19 37 3 30 58 11 25 43 17 34 18 26 1 4 29 31 8 16 46 15 33 22 35 6 24 41 20 96 23 27

result:

ok correct

Test #33:

score: 17
Accepted
time: 0ms
memory: 3764kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
50 625 30000
43 10
21 5
12 24
8 3
16 18
32 28
41 39
26 40
1 7
47 48
42 43
44 29
6 35
9 22
37 33
27 23
10 19
25 45
46 2
17 15
38 34
0 31
20 49
13 11
36 4
6 36
8 48
36 16
15 49
22 17
7 32
34 29
19 13
30 18
7 0
26 29
15 8
43 6
22 25
12 10
6 8
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
8 34 3 40 39 23 36 19 4 16 32 1 47 13 29 75 2 43 38 15 42 35 33 21 5 30 59 31 41 12 24 25 27 14 20 57 7 6 46 0 10 37 11 17 18 9 26 22 28

result:

ok correct

Subtask #3:

score: 21
Accepted

Dependency #2:

100%
Accepted

Test #34:

score: 21
Accepted
time: 164ms
memory: 4944kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 28680 30000
77 105
206 25
9 149
62 63
186 223
157 69
181 222
103 184
97 50
227 3
60 109
51 3
188 65
213 224
33 209
133 213
84 23
189 158
138 141
191 195
221 106
44 49
195 86
90 231
202 204
83 43
192 37
46 21
76 34
126 234
59 213
197 41
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
20517 12868 6526 13587 15583 27789 2642 3778 27130 10468 21971 3758 22158 10388 12960 8170 25311 4510 28468 3914 10839 27534 24586 8508 28378 11542 21027 26767 3704 2980 4586 14004 9381 11339 1853 8498 3185 25651 14507 25858 12225 16219 ...

result:

ok correct

Test #35:

score: 21
Accepted
time: 145ms
memory: 4888kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 27680 30000
200 15
124 32
165 159
220 160
218 108
124 92
144 70
107 93
63 84
18 154
3 94
100 133
214 205
58 89
206 16
17 141
122 155
140 199
37 195
165 236
162 136
142 124
3 168
205 149
99 61
210 89
81 100
185 15
131 179
106 5
11 215
16...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
6133 8189 15657 17008 21768 3978 15171 5525 10443 4390 5749 10451 25027 21744 15562 15921 11349 13144 20725 2950 21030 23371 498 6678 16702 19350 21409 17036 7259 19716 8911 951 21655 26043 8232 14654 27439 15775 17192 21518 4114 990 186...

result:

ok correct

Test #36:

score: 21
Accepted
time: 87ms
memory: 4648kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 19000 30000
202 130
117 5
108 72
44 63
37 77
174 221
63 193
228 218
176 98
37 131
174 32
212 211
70 131
238 213
186 170
78 17
214 46
132 50
224 48
182 84
117 187
219 25
26 7
64 117
57 213
32 193
223 205
92 110
238 142
125 98
26 126
156 ...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
17273 11549 6765 5180 1239 6948 14785 8083 633 5634 11567 11147 9508 18617 16373 14508 3767 12972 7089 8746 7604 14268 7984 10289 15124 765 7664 5684 11315 10507 11304 11776 5898 18092 10093 5713 10509 1524 18330 13314 3385 13749 14968 8...

result:

ok correct

Test #37:

score: 21
Accepted
time: 5ms
memory: 3884kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 1200 30000
69 37
167 58
236 35
109 163
146 70
157 29
171 159
21 97
160 87
0 175
66 39
67 105
44 23
28 19
68 239
191 21
206 176
16 4
147 217
5 213
162 9
235 23
29 24
88 37
154 79
120 30
37 113
40 136
188 83
62 65
83 115
186 228
89 177
84...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
879 1081 189 118 537 871 280 185 1182 154 190 624 1042 1142 810 933 187 115 534 542 1049 308 674 1198 713 63 473 58 531 503 821 235 310 688 733 1018 523 988 227 92 177 409 330 1083 281 487 557 718 754 53 1056 26 636 553 1102 778 765 1057...

result:

ok correct

Test #38:

score: 21
Accepted
time: 162ms
memory: 4984kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 28500 30000
39 121
47 231
20 137
46 76
236 198
129 155
195 39
68 232
68 213
149 87
10 87
27 191
39 58
124 116
174 14
24 41
52 42
221 180
103 193
197 28
170 84
152 166
51 145
123 120
1 5
75 67
61 207
80 160
62 118
62 191
153 72
230 51
13...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
11412 19976 8038 23711 27777 24694 26547 5535 5955 9925 18945 26349 8622 569 24178 18473 18037 9882 22584 11798 12033 13765 1292 15848 4654 6031 20698 11467 2313 6182 4853 16254 99 26172 23629 27888 22211 27545 23246 1363 18253 10723 950...

result:

ok correct

Test #39:

score: 21
Accepted
time: 140ms
memory: 4640kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 24300 30000
224 91
45 219
129 54
171 116
139 153
2 122
62 154
136 43
138 86
228 85
88 18
146 135
116 0
230 107
165 42
142 137
152 10
191 238
76 196
196 90
181 187
150 232
166 24
32 213
59 89
87 52
102 79
167 119
89 202
111 19
142 20
142...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
12370 10902 19105 17267 818 20375 9197 11627 19853 6915 22224 8844 13735 16282 23956 16403 2273 18400 20416 21147 1368 20296 9609 4848 9379 7330 6289 7140 9141 6090 8966 10773 17406 20279 5332 10951 22846 2220 9679 14871 15709 18670 2019...

result:

ok correct

Test #40:

score: 21
Accepted
time: 104ms
memory: 4828kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 19000 30000
213 152
122 131
131 30
199 167
218 66
136 31
35 118
209 45
87 214
160 210
204 179
99 199
92 36
208 161
101 237
169 231
96 229
220 184
36 169
126 198
167 113
95 188
117 142
41 139
4 191
7 214
0 41
123 73
90 1
228 115
206 106
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
6397 6298 10948 15357 7712 10421 7174 17715 6715 11879 2090 6699 14527 15338 17870 12390 13541 8453 11297 12193 18329 15971 13821 1456 12679 7078 10898 16617 13236 5522 2947 15305 16792 5104 15262 8497 16273 4708 9163 14570 733 1018 2601...

result:

ok correct

Test #41:

score: 21
Accepted
time: 333ms
memory: 4664kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 28680 30000
152 222
33 34
198 107
131 148
28 9
147 195
21 176
229 96
33 199
123 227
88 224
228 154
150 4
105 49
37 54
19 127
103 55
132 157
87 167
223 129
223 47
121 21
16 83
80 112
94 21
219 161
233 23
15 4
143 104
163 107
54 77
25 32
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
222 386 497 590 844 879 953 1129 1346 1550 1617 1621 1627 1760 1786 1957 2081 2226 2230 2268 2319 2343 2398 2488 2500 2544 2625 2664 2917 3083 3126 3132 3350 3407 3422 3458 3558 3618 3903 4084 4203 4403 4508 4553 4659 4891 5286 5510 5655...

result:

ok correct

Test #42:

score: 21
Accepted
time: 331ms
memory: 4804kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 28580 30000
94 118
196 100
226 142
45 93
169 133
226 104
28 139
183 27
83 150
109 15
163 94
15 81
19 127
77 131
163 19
140 123
210 183
77 186
137 217
209 34
213 10
105 10
237 62
215 21
117 165
98 226
39 155
137 91
80 122
109 36
179 192
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
98 154 184 244 552 713 717 753 1340 1347 1363 1393 1394 1488 1703 1825 2007 2083 2217 2354 2361 2440 2462 2472 2622 2737 2871 3055 3163 3165 3310 3393 3476 3521 3562 3627 3820 3854 3951 4122 4128 4384 4734 4952 5022 5132 5226 5276 5326 5...

result:

ok correct

Test #43:

score: 21
Accepted
time: 130ms
memory: 4828kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 15181 30000
85 75
184 0
175 129
194 123
142 28
187 46
144 198
122 72
30 184
93 92
24 173
123 104
26 49
27 41
12 210
160 151
112 138
229 205
43 200
81 85
0 97
74 161
110 185
164 186
122 127
219 181
32 213
192 49
4 211
19 115
180 227
52 1...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
191 238 136 127 13 103 95 12 31 36 128 182 246 33 93 101 212 49 258 76 223 114 52 124 125 0 19 202 78 40 174 129 9 155 190 43 140 411 463 20 112 142 239 57 85 92 144 120 210 68 143 233 47 60 280 180 58 132 272 29 286 41 90 46 172 149 151...

result:

ok correct

Test #44:

score: 21
Accepted
time: 100ms
memory: 4576kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 12182 30000
65 20
13 163
23 228
96 62
37 143
6 29
129 121
108 162
51 34
21 199
227 25
227 208
72 80
121 17
139 227
146 193
169 89
6 50
76 137
2 232
196 125
182 64
10 178
90 19
142 6
24 100
80 57
27 185
202 225
42 125
66 23
7 5
18 49
12 ...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
31 370 129 117 98 378 86 5 73 32 17 8 89 97 123 164 71 101 257 200 45 102 170 49 0 30 47 119 113 54 55 136 12 26 152 59 137 62 23 194 296 3 34 25 33 60 76 37 39 57 209 226 128 41 538 118 107 192 320 13 124 191 64 94 29 92 99 6855 84 188 ...

result:

ok correct

Test #45:

score: 21
Accepted
time: 124ms
memory: 4696kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 14281 30000
185 117
86 83
197 227
78 60
119 134
10 88
216 206
9 74
89 237
21 57
99 6
47 53
214 100
140 237
141 131
210 234
183 206
196 235
37 91
161 144
63 112
227 72
0 3
59 10
231 1
223 67
94 56
86 57
155 133
120 134
232 160
168 180
78...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
22 232 41 441 75 147 166 56 146 235 11 42 91 9 67 23 137 450 195 99 136 2079 7 133 139 3 208 153 192 150 323 1 27 5 152 18 26 127 93 78 10 174 229 39 134 71 304 62 102 125 212 20 52 194 233 64 149 222 105 47 81 106 112 120 104 44 88 43 4...

result:

ok correct

Test #46:

score: 21
Accepted
time: 88ms
memory: 4324kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 10682 30000
158 52
46 225
215 8
82 232
96 15
138 127
62 153
87 88
61 215
129 49
172 28
224 171
87 53
195 215
47 224
91 209
55 227
83 130
59 107
18 238
210 23
225 60
104 51
130 113
72 160
236 65
87 174
111 30
96 175
226 139
99 227
35 5
2...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
103 63 183 31 79 191 331 167 111 47 88 77 2128 339 120 68 175 208 129 166 405 80 548 203 81 240 12 55 7 280 357 74 4 43 263 278 174 51 198 1094 86 22 33 38 309 127 18 61 48 27 168 158 144 471 152 224 96 244 233 314 709 217 162 311 9 17 2...

result:

ok correct

Test #47:

score: 21
Accepted
time: 28ms
memory: 4028kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 4685 30000
47 83
235 230
162 108
46 147
229 72
72 173
114 71
121 113
143 162
51 214
121 51
239 118
197 48
158 150
21 64
0 236
160 67
218 188
29 79
8 85
142 4
26 153
73 114
78 137
91 87
224 116
211 87
22 62
106 85
19 125
26 162
14 210
12...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
62 176 170 116 312 216 70 238 142 149 253 101 27 228 240 14 169 76 164 132 177 129 131 199 205 18 90 208 0 186 19 103 204 96 24 146 123 189 47 516 178 28 98 152 50 231 6 22 319 107 108 7 10 74 168 220 75 29 272 203 64 94 159 211 294 148 ...

result:

ok correct

Test #48:

score: 21
Accepted
time: 0ms
memory: 3768kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 419 30000
117 72
112 209
19 107
171 168
236 144
123 226
96 126
67 51
63 121
234 169
154 97
222 37
52 211
160 36
179 177
234 36
182 59
93 218
64 8
207 215
27 16
208 73
214 157
218 199
154 28
68 239
41 150
184 59
63 147
37 210
134 148
132...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
122 161 244 20 302 124 164 97 309 87 69 250 115 171 267 206 227 18 60 7 184 70 166 185 56 231 408 121 318 83 337 39 143 214 226 212 173 105 32 54 137 148 2 42 108 200 64 215 81 181 0 129 126 197 217 57 59 241 8 66 155 71 357 86 6 112 75 ...

result:

ok correct

Test #49:

score: 21
Accepted
time: 8ms
memory: 3896kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 1340 30000
100 43
227 35
6 89
210 126
155 31
166 168
19 80
210 107
5 209
79 33
122 24
171 39
84 94
163 42
78 84
38 51
34 121
85 95
90 178
152 59
82 26
7 118
206 163
229 124
184 19
179 176
159 189
203 11
1 43
18 203
15 21
205 220
40 26
2...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
187 132 30 941 84 568 32 170 125 28 72 15 87 60 91 366 99 112 159 148 973 1036 9 6 165 315 20 147 14 341 730 2 466 1058 12 17 182 313 169 176 0 108 281 109 331 35 156 201 75 56 67 172 207 37 83 175 95 160 21 120 16 46 250 10 185 398 230 ...

result:

ok correct

Test #50:

score: 21
Accepted
time: 35ms
memory: 4248kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 4686 30000
109 222
129 207
41 85
155 232
104 110
7 9
15 182
92 132
160 23
167 223
130 191
7 170
183 20
97 154
55 130
199 143
125 112
225 196
70 182
48 178
204 64
51 86
210 7
175 98
71 70
29 185
205 105
227 79
196 191
138 114
161 146
56 ...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
180 5 142 252 255 86 322 325 92 257 256 31 37 146 60 85 102 124 24 70 421 222 279 46 174 35 115 262 320 93 863 2 21 56 158 43 113 140 143 343 40 168 292 41 129 84 110 77 32 4 52 254 220 74 294 61 87 88 145 211 281 230 159 16 118 132 156 ...

result:

ok correct

Test #51:

score: 21
Accepted
time: 121ms
memory: 4428kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 14282 30000
196 64
31 209
73 50
28 224
168 66
104 116
85 67
125 143
226 195
211 55
58 22
113 45
89 51
214 152
38 110
25 83
156 192
162 233
217 203
94 234
59 139
109 107
144 223
104 73
102 196
175 192
61 238
118 46
152 40
16 149
148 155
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
373 214 258 227 339 409 245 67 49 102 171 113 284 10 136 456 40 294 89 80 216 93 2 109 75 101 131 142 78 98 15 87 6 47 12 149 226 301 91 54 57 45 163 23 401 127 21 95 14 81 460 110 11 38 85 262 185 152 169 5 27 204 153 107 151 224 265 33...

result:

ok correct

Test #52:

score: 21
Accepted
time: 102ms
memory: 4420kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 12183 30000
142 57
209 190
111 176
210 233
189 107
185 47
168 179
156 83
91 35
176 84
68 78
169 103
212 93
222 81
112 170
14 238
113 215
159 122
116 173
132 27
137 139
203 212
137 238
129 2
108 70
35 106
20 128
221 198
170 106
52 66
128...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
121 53 67 106 311 279 253 131 303 275 341 78 49 41 29 59 164 80 129 142 264 10 109 184 202 490 51 351 281 8 372 38 94 48 226 145 177 140 178 124 25 138 24 77 159 244 179 246 169 55 96 88 74 26 30 208 23 100 158 19 82 816 110 156 64 122 3...

result:

ok correct

Test #53:

score: 21
Accepted
time: 102ms
memory: 4516kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 10683 30000
169 36
164 166
236 70
211 50
140 122
204 14
97 30
153 145
55 238
163 214
185 130
36 74
127 139
218 48
184 214
157 238
180 37
86 145
135 6
30 129
159 200
48 118
114 61
193 12
66 128
79 82
24 102
25 77
56 59
118 38
128 153
181...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
96 190 58 210 223 459 108 119 85 98 65 28 162 62 126 153 100 68 11 6728 27 25 56 150 550 116 250 168 917 61 112 239 34 6 36 72 64 390 26 81 39 225 120 192 792 175 224 102 203 323 457 227 288 88 142 285 22 156 131 21 29 47 51 76 82 89 137...

result:

ok correct

Test #54:

score: 21
Accepted
time: 147ms
memory: 4548kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 15182 30000
173 21
231 223
56 97
175 160
1 181
205 59
177 0
158 194
220 0
90 31
104 239
181 204
29 221
9 169
106 38
196 48
119 141
213 48
25 104
35 175
126 160
149 70
110 131
14 172
37 35
162 110
149 121
13 231
40 191
79 102
64 2
98 156...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
136 117 46 24 33 137 158 347 238 484 293 91 187 114 30 75 86 285 65 83 367 34 82 90 40 151 68 450 9 70 87 180 81 2 263 112 269 29 18 196 358 14 77 67 268 211 593 71 111 148 138 2949 234 295 113 213 110 323 96 131 184 224 121 194 66 426 2...

result:

ok correct

Test #55:

score: 21
Accepted
time: 104ms
memory: 4448kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 14400 30000
219 122
167 73
229 205
178 62
203 85
11 210
179 124
188 23
80 98
180 156
217 0
135 7
2 104
61 138
47 108
237 77
224 126
164 75
84 34
92 212
83 233
68 128
102 78
94 140
27 155
4 107
225 111
132 87
195 37
142 13
117 90
129 28
...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
60 64 200 150 167 138 191 71 36 273 86 55 184 129 41 166 67 66 88 154 217 80 202 101 97 124 18 140 113 252 152 118 95 197 61 98 123 8 196 143 77 79 159 22 141 12 298 44 25 156 14 48 130 157 258 62 125 30 149 99 38 209 243 105 21 31 27 19...

result:

ok correct

Test #56:

score: 21
Accepted
time: 89ms
memory: 4476kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 14400 30000
175 171
220 96
214 27
48 205
75 200
8 166
76 10
213 67
62 168
31 69
39 4
128 36
6 79
178 107
224 104
20 185
49 45
60 160
119 72
148 159
141 226
24 35
194 54
2 15
209 232
44 228
149 50
234 66
57 172
25 196
195 239
144 115
100...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
23 57 150 94 21 10 291 215 133 16 235 153 334 66 142 181 161 81 9 123 109 256 6 97 257 12 199 120 258 371 200 100 40 137 166 204 132 111 191 68 73 135 178 32 130 103 141 47 216 86 173 42 18 35 155 195 65 228 184 165 183 11 76 139 188 113...

result:

ok correct

Test #57:

score: 21
Accepted
time: 98ms
memory: 4668kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
240 14400 30000
233 129
228 221
18 89
77 107
168 125
238 219
32 150
132 46
34 193
222 27
83 167
206 177
15 146
210 218
187 128
25 75
195 39
105 56
156 233
79 124
220 215
164 183
194 68
211 52
62 142
207 1
14 189
8 61
95 33
144 154
136 160
4...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
238 55 58 151 115 147 216 210 31 37 35 141 43 38 150 27 188 166 192 53 15 103 175 255 121 162 250 32 157 2 117 42 134 181 186 28 64 63 90 153 91 124 228 17 152 3 110 119 139 76 217 75 190 78 251 87 52 113 144 84 67 120 94 74 125 19 285 1...

result:

ok correct

Subtask #4:

score: 0
Wrong Answer

Test #58:

score: 19
Accepted
time: 0ms
memory: 3768kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
2 1 12000
1 0
0

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
0

result:

ok correct

Test #59:

score: 19
Accepted
time: 0ms
memory: 3792kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
10 45 12000
4 8
0 5
2 0
5 8
8 0
3 8
6 4
4 1
2 3
2 1
6 2
1 7
3 7
8 1
7 0
8 6
0 6
9 5
9 6
7 4
7 6
7 9
1 6
3 5
2 5
7 5
3 9
0 3
3 6
2 9
1 5
0 4
7 8
5 4
9 4
5 6
3 1
2 8
7 2
2 4
1 0
9 8
4 3
1 9
9 0
22 41 3 16 7 25 28 11 39

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
OK
7 39 16 22 28 11 25 3 41

result:

ok correct

Test #60:

score: 0
Wrong Answer
time: 126ms
memory: 7344kb

input:

wrslcnopzlckvxbnair_input_simurgh_lmncvpisadngpiqdfngslcnvd
400 79800 12000
32 64
96 254
115 203
7 171
112 81
124 143
336 175
217 328
152 133
124 331
19 91
92 232
152 43
215 169
4 341
363 18
83 99
52 46
248 66
242 187
150 319
335 158
172 150
3 49
126 256
60 153
165 230
265 68
119 380
171 22
35 169
3...

output:

lxndanfdiadsfnslkj_output_simurgh_faifnbsidjvnsidjbgsidjgbs
WA
NO

result:

wrong answer WA in grader: NO

Subtask #5:

score: 0
Skipped

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

100%
Accepted

Dependency #4:

0%