QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#535491#8726. Magic ShowWansur0 152ms19776kbC++231.0kb2024-08-28 05:53:482024-08-28 05:53:48

Judging History

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

  • [2024-08-28 05:53:48]
  • 评测
  • 测评结果:0
  • 用时:152ms
  • 内存:19776kb
  • [2024-08-28 05:53:48]
  • 提交

Alice

#include "Alice.h"
#include <bits/stdc++.h>

using namespace std;
typedef long long ll;

mt19937 rng(92783458);

int p[5001];

int get(int x){
    if(p[x] == x) return x;
    return p[x] = get(p[x]);
}

vector<pair<int,int>> Alice(){
    vector<pair<int, int>> edge, ans;
    int n = 5000;
    ll x = setN(n);
    for(int i=1;i<=n;i++){
        p[i] = i;
    }
    for(int i=1;i<=n;i++){
        for(int j=i+1;j<=n;j++){
            if((x & (1ll << ((i + j) % 60)))){
                edge.push_back({i, j});
            }
        }
    }
    shuffle(edge.begin(), edge.end(), rng);
    for(auto [x, y]:edge){
        if(get(x) != get(y)){
            ans.push_back({x, y});
            p[get(x)] = get(y);
        }
    }
    return ans;
}

Bob

#include <bits/stdc++.h>
#include "Bob.h"

using namespace std;
typedef long long ll;

long long Bob(std::vector<std::pair<int,int>> edge){
    ll ans = 0;
    for(auto [x, y]:edge){
        ans |= (1ll << (x + y));
    }
    return ans;
}

详细

Subtask #1:

score: 0
Wrong Answer

Test #1:

score: 0
Wrong Answer
time: 30ms = 30ms + 0ms
memory: 19776kb,1836kb

input:

1
4005

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
5000
4569 4971
901 2404
185 4135
3862 4005
2807 3504
3108 3374
1471 3338
3929 4951
1991 4377
3580 4290
1790 3200
596 2055
2822 3658
54 1328
2278 4989
2532 4558
1092 4917...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
5000
4569 4971
901 2404
185 4135
3862 4005
2807 3504
3108 3374
1471 3338
3929 4951
1991 4377
3580 4290
1790 3200
596 2055
2822 3658
54 1328
2278 4989
2532 4558
1092 4917...

output:

2
5000 4821
1 121
2 4449
3 608
3 787
3 904
3 4568
4 2226
5 604
5 3422
6 1862
6 2282
7 63
8 1501
9 1133
9 4982
10 1319
10 4198
10 4560
11 3411
11 4678
12 4548
13 1138
14 597
14 1494
14 3776
15 1545
15 2630
16 3712
17 291
17 1905
17 4845
18 950
18 2870
18 3530
19 1001
19 1490
20 1311
21 3170
21 3281
2...

input:

2
5000 4821
1 121
2 4449
3 608
3 787
3 904
3 4568
4 2226
5 604
5 3422
6 1862
6 2282
7 63
8 1501
9 1133
9 4982
10 1319
10 4198
10 4560
11 3411
11 4678
12 4548
13 1138
14 597
14 1494
14 3776
15 1545
15 2630
16 3712
17 291
17 1905
17 4845
18 950
18 2870
18 3530
19 1001
19 1490
20 1311
21 3170
21 3281
2...

output:

9ff923928e5675d6f7ae686fcfb20beac84bc7b1a47cf13bde24b59497bcae3b4900097049e1c568aa409defdbadf4cfc599c0e496e22068170cce547295ffa4
Incorrect answer.

Subtask #2:

score: 0
Wrong Answer

Test #13:

score: 0
Wrong Answer
time: 47ms = 47ms + 0ms

input:

1
17476204

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
5000
2363 4120
3709 4160
134 3535
2214 4511
1788 3858
2468 3958
2394 4943
2234 3235
1339 4074
2122 2623
1217 2522
426 1385
1796 2361
39 3154
1507 1555
1646 4733
767 1346...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
5000
2363 4120
3709 4160
134 3535
2214 4511
1788 3858
2468 3958
2394 4943
2234 3235
1339 4074
2122 2623
1217 2522
426 1385
1796 2361
39 3154
1507 1555
1646 4733
767 1346...

output:

2
5000 4821
1 1568
1 4141
2 1871
2 2842
2 2941
3 2528
3 4982
4 1991
4 4501
5 1804
5 1934
6 1449
7 2635
7 3552
8 661
8 916
8 3714
8 4627
9 3135
10 2575
10 3189
10 4865
11 3238
12 3234
12 4383
13 1553
13 2342
13 3731
14 1381
14 4908
15 542
16 2761
16 3481
16 4868
17 48
18 2821
18 4784
19 4970
20 702
2...

input:

2
5000 4821
1 1568
1 4141
2 1871
2 2842
2 2941
3 2528
3 4982
4 1991
4 4501
5 1804
5 1934
6 1449
7 2635
7 3552
8 661
8 916
8 3714
8 4627
9 3135
10 2575
10 3189
10 4865
11 3238
12 3234
12 4383
13 1553
13 2342
13 3731
14 1381
14 4908
15 542
16 2761
16 3481
16 4868
17 48
18 2821
18 4784
19 4970
20 702
2...

output:

9ff923928e5675d6f7ae686fcfb20beac84bc7b1a47cf13bde24b59497bcae3b4900097049e1c568aa409defdbadf4cfc599c0e496e22068170cce547295ffa4
Incorrect answer.

Subtask #3:

score: 0
Wrong Answer

Test #25:

score: 0
Wrong Answer
time: 152ms = 152ms + 0ms
memory: 2304kb,1844kb

input:

1
355365355024496523

output:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
5000
1411 1944
4263 4925
1057 1419
1386 2501
1679 1688
664 3369
650 1065
1996 4452
2177 4931
1457 2598
2188 4583
3146 3534
518 4021
13 4204
3143 4918
482 2961
1801 2757
...

input:

a890c6696058af3ad84e267191c856938f206a8ef7c63581510cdfa15e45f9c07d82b6a58fe3c8183e2b8f4b976dd90fbca50f420ce3dcf29a3d6a73adf47022
1
5000
1411 1944
4263 4925
1057 1419
1386 2501
1679 1688
664 3369
650 1065
1996 4452
2177 4931
1457 2598
2188 4583
3146 3534
518 4021
13 4204
3143 4918
482 2961
1801 2757
...

output:

2
5000 4821
1 2303
1 3053
1 4194
2 8
2 1518
3 1915
4 1642
4 4423
5 791
5 2130
5 2419
6 4257
6 4903
7 3721
7 4871
8 1865
8 3882
9 1632
9 3406
10 2740
11 1944
11 3970
12 73
12 1415
12 3687
12 3697
13 4204
14 3792
15 3459
16 3031
17 884
17 2404
18 792
19 2504
20 4448
21 1975
21 4735
22 299
23 1549
24 2...

input:

2
5000 4821
1 2303
1 3053
1 4194
2 8
2 1518
3 1915
4 1642
4 4423
5 791
5 2130
5 2419
6 4257
6 4903
7 3721
7 4871
8 1865
8 3882
9 1632
9 3406
10 2740
11 1944
11 3970
12 73
12 1415
12 3687
12 3697
13 4204
14 3792
15 3459
16 3031
17 884
17 2404
18 792
19 2504
20 4448
21 1975
21 4735
22 299
23 1549
24 2...

output:

9ff923928e5675d6f7ae686fcfb20beac84bc7b1a47cf13bde24b59497bcae3b4900097049e1c568aa409defdbadf4cfc599c0e496e22068170cce547295ffa4
Incorrect answer.