QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#83313#1974. Black Family TreeZhaoZiLongWA 4ms8096kbC++171.8kb2023-03-01 13:26:252023-03-01 13:26:29

详细

Test #1:

score: 100
Accepted
time: 1ms
memory: 8060kb

input:

6 5
1 2 4 8 16 32
1 2 2 1 5
1 1
2 3
4 5
2 6
6 6

output:

63
14
56
62
32

result:

ok 5 lines

Test #2:

score: 0
Accepted
time: 2ms
memory: 8096kb

input:

5 25
4723 3513 2046 6286 9584
1 2 2 1
1 5
5 5
2 3
2 3
4 4
2 4
2 2
1 2
2 5
3 3
2 2
1 3
2 4
1 5
2 2
3 3
3 5
2 5
1 3
1 5
2 3
4 5
4 4
4 4
1 3

output:

26152
9584
11845
11845
6286
11845
11845
26152
21429
2046
11845
26152
11845
26152
11845
2046
17916
21429
26152
26152
11845
15870
6286
6286
26152

result:

ok 25 lines

Test #3:

score: -100
Wrong Answer
time: 4ms
memory: 8068kb

input:

10 100
1457 936 8200 7604 1431 2726 6728 2545 3010 267
1 2 3 4 5 2 1 6 6
1 9
7 7
4 4
3 10
4 7
2 2
2 10
6 8
4 7
3 10
8 8
3 10
4 6
4 4
4 8
5 9
1 1
5 7
5 10
9 9
6 8
6 6
10 10
2 4
1 5
7 9
2 3
4 10
3 8
2 10
6 10
5 7
1 1
4 5
3 5
6 8
7 7
2 5
3 3
7 9
2 10
1 8
1 2
1 4
1 10
3 4
4 7
3 4
2 2
2 10
2 3
1 9
3 4
9 ...

output:

34904
6728
15038
32511
21766
30902
33447
15276
21766
32511
2545
32511
15038
15038
24311
16707
34904
14162
16707
3010
15276
6003
267
30902
34904
12550
30902
24311
32511
33447
15276
14162
34904
15038
23238
15276
6728
30902
23238
12550
33447
34904
34904
34904
34904
23238
21766
23238
30902
33447
30902
3...

result:

wrong answer 26th lines differ - expected: '12283', found: '12550'