QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#37257#2831. Game TheoryZhaoZiLongRE 53ms7820kbC++172.0kb2022-06-30 17:51:352022-06-30 17:51:36

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 2ms
memory: 7820kb

input:

3 2
010
1 2
2 3
5 1
00000
1 5

output:

1
3
5

result:

ok 3 lines

Test #2:

score: 0
Accepted
time: 3ms
memory: 7540kb

input:

1 1
0
1 1

output:

1

result:

ok single line: '1'

Test #3:

score: 0
Accepted
time: 53ms
memory: 7680kb

input:

2 2
01
2 2
2 2
2 2
01
1 2
1 2
1 2
1
1 1
1 1
1 2
1
1 1
1 1
2 2
00
1 2
1 2
2 2
11
1 2
1 2
2 2
01
2 2
1 1
2 2
10
2 2
1 2
2 2
01
1 2
1 2
1 2
0
1 1
1 1
2 2
01
1 2
2 2
1 2
0
1 1
1 1
1 2
1
1 1
1 1
2 2
10
1 2
1 1
1 2
0
1 1
1 1
2 2
01
1 2
1 2
2 2
10
1 2
1 1
1 2
0
1 1
1 1
1 2
0
1 1
1 1
1 2
1
1 1
1 1
2 2
10
1 ...

output:

0
3
1
3
0
1
0
1
2
0
0
2
0
1
2
0
1
3
1
0
1
2
1
0
0
1
3
2
1
0
1
3
3
2
1
0
1
0
0
1
0
1
0
2
2
1
0
1
2
1
1
0
2
0
2
3
1
0
0
1
2
0
0
1
0
1
0
1
1
0
1
2
2
0
0
2
0
1
0
1
1
0
1
0
1
0
0
1
0
1
0
1
2
0
3
0
1
0
0
1
1
0
1
0
1
2
0
2
1
0
0
3
1
2
0
1
3
2
1
0
0
1
2
0
2
0
0
1
0
1
1
0
1
0
1
0
1
0
1
2
1
0
3
1
0
3
0
1
0
1
...

result:

ok 200000 lines

Test #4:

score: -100
Runtime Error

input:

11 20
00010111000
1 6
1 11
5 6
8 11
1 4
3 8
4 11
1 7
5 9
1 4
6 10
5 6
1 7
5 10
1 10
9 11
6 8
1 4
8 11
1 4
10 20
0101000010
3 4
2 2
4 8
4 6
6 7
3 7
3 3
1 5
1 5
6 8
2 2
2 4
2 6
5 7
1 3
2 5
6 8
7 9
5 8
3 10
4 20
1011
2 4
1 4
1 3
2 3
1 1
2 2
1 2
2 4
1 2
3 4
3 4
3 4
1 4
2 2
1 4
1 3
1 1
1 3
1 3
2 2
4 20
1...

output:

4
55
53
31
21
15
69
62
56
10
25
63
56
60
48
29
33
33
63
63
21
22
35
44
42
41
42
19
42
29
24
37
22
23
38
38
11
10
22
46
2
12
5
11
12
11
11
2
0
12
0
12
2
1
11
6
7
4
7
10
4
11
1
8
10
3
5
7
3
7
6
10
6
11
6
11
2
0
5
3
108
161
135
-58
136
119
112
98
105
112
147
72
81
36
100
73
96
58
69
-27
48
51
25
21
34
...

result: