QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#518969#2549. King's PalaceUrdWA 193ms87648kbC++171.4kb2024-08-14 14:52:072024-08-14 14:52:07

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 155ms
memory: 69300kb

input:

2 3
1 R 2 R
1 G 2 R
1 B 2 G

output:

6

result:

ok answer is '6'

Test #2:

score: 0
Accepted
time: 158ms
memory: 71036kb

input:

1 0

output:

3

result:

ok answer is '3'

Test #3:

score: 0
Accepted
time: 193ms
memory: 69844kb

input:

22 0

output:

31381059609

result:

ok answer is '31381059609'

Test #4:

score: 0
Accepted
time: 153ms
memory: 69844kb

input:

4 12
2 R 3 R
1 B 2 B
2 R 3 B
3 R 4 R
1 B 4 G
1 R 3 B
3 G 4 B
2 G 3 G
1 B 2 R
1 G 2 R
1 R 3 G
1 G 3 B

output:

13

result:

ok answer is '13'

Test #5:

score: 0
Accepted
time: 150ms
memory: 70584kb

input:

2 4
1 G 2 G
1 B 2 R
1 R 2 G
1 B 2 B

output:

5

result:

ok answer is '5'

Test #6:

score: 0
Accepted
time: 159ms
memory: 70304kb

input:

5 77
3 B 5 B
2 G 5 G
4 R 5 G
1 G 2 B
1 R 4 R
4 B 5 G
2 B 3 G
2 G 5 B
1 R 3 G
2 R 5 R
3 B 4 R
1 R 2 B
3 G 4 G
1 B 5 G
3 R 5 G
3 G 4 B
1 B 4 G
4 B 5 R
2 R 4 G
1 G 4 B
2 G 3 R
2 R 5 B
1 G 2 R
2 B 4 R
2 R 3 R
3 B 5 G
2 G 3 G
1 R 3 R
1 R 5 G
2 G 3 B
3 B 4 B
4 R 5 B
1 R 2 G
3 G 5 R
1 R 2 R
2 B 5 B
3 B 5 R...

output:

0

result:

ok answer is '0'

Test #7:

score: 0
Accepted
time: 152ms
memory: 70344kb

input:

10 141
3 B 9 B
1 R 8 R
4 B 8 R
2 B 4 R
2 R 7 B
6 B 9 R
1 R 9 R
4 R 8 G
3 B 8 R
3 B 5 G
4 B 9 B
4 G 5 R
2 R 3 G
7 B 8 G
5 B 7 R
7 B 8 R
2 B 8 B
7 R 10 B
2 G 10 G
6 G 8 B
1 R 4 B
8 R 10 B
2 G 3 B
2 B 5 B
3 R 4 R
3 B 7 R
3 R 7 R
2 R 10 R
3 G 9 G
5 B 10 G
6 R 8 B
3 R 9 G
1 B 10 G
3 R 8 G
1 B 3 R
4 R 9 R...

output:

0

result:

ok answer is '0'

Test #8:

score: 0
Accepted
time: 162ms
memory: 69144kb

input:

22 2079
1 R 2 R
1 R 2 G
1 R 2 B
1 G 2 R
1 G 2 G
1 G 2 B
1 B 2 R
1 B 2 G
1 B 2 B
1 R 3 R
1 R 3 G
1 R 3 B
1 G 3 R
1 G 3 G
1 G 3 B
1 B 3 R
1 B 3 G
1 B 3 B
1 R 4 R
1 R 4 G
1 R 4 B
1 G 4 R
1 G 4 G
1 G 4 B
1 B 4 R
1 B 4 G
1 B 4 B
1 R 5 R
1 R 5 G
1 R 5 B
1 G 5 R
1 G 5 G
1 G 5 B
1 B 5 R
1 B 5 G
1 B 5 B
1 R ...

output:

0

result:

ok answer is '0'

Test #9:

score: 0
Accepted
time: 161ms
memory: 70216kb

input:

4 52
1 G 2 B
2 G 4 R
1 G 4 B
1 G 3 G
3 B 4 B
2 R 4 B
2 G 3 G
3 B 4 R
1 B 2 B
1 G 4 G
3 G 4 B
1 B 4 R
3 R 4 G
2 B 4 B
1 G 2 G
3 G 4 G
2 R 3 R
1 R 3 G
2 R 4 G
2 B 3 B
2 B 3 G
2 R 3 G
1 B 3 G
1 G 4 R
1 G 2 R
2 G 4 B
1 G 3 R
1 R 2 R
1 R 2 G
1 R 4 G
2 R 4 R
2 B 3 R
1 B 3 B
2 B 4 R
3 R 4 R
2 G 4 G
3 B 4 G...

output:

0

result:

ok answer is '0'

Test #10:

score: 0
Accepted
time: 148ms
memory: 70576kb

input:

8 10
1 G 7 R
7 R 8 G
3 R 6 R
3 G 4 R
5 B 8 R
4 B 6 G
2 G 5 B
1 R 2 B
7 G 8 G
3 G 5 R

output:

1874

result:

ok answer is '1874'

Test #11:

score: 0
Accepted
time: 158ms
memory: 69392kb

input:

4 40
2 G 3 G
1 R 4 R
3 G 4 G
1 R 3 R
1 G 2 G
2 R 3 R
3 R 4 R
1 G 2 B
1 B 4 R
1 B 3 R
1 G 4 R
2 R 4 G
1 B 2 R
1 B 4 G
1 G 3 R
1 G 4 G
2 G 3 B
1 B 2 G
1 R 3 G
1 R 2 B
1 B 3 B
2 B 3 R
1 B 3 G
1 G 4 B
1 G 3 G
2 G 3 R
1 R 4 G
2 B 4 B
2 G 4 R
3 R 4 B
2 R 4 B
1 R 2 G
2 B 4 R
1 B 2 B
1 G 3 B
2 G 4 B
1 R 3 B...

output:

0

result:

ok answer is '0'

Test #12:

score: 0
Accepted
time: 162ms
memory: 69932kb

input:

2 3
1 B 2 B
1 R 2 R
1 G 2 R

output:

6

result:

ok answer is '6'

Test #13:

score: 0
Accepted
time: 165ms
memory: 71160kb

input:

3 24
1 R 2 B
1 B 3 B
2 G 3 B
1 B 2 G
1 B 2 B
2 R 3 G
1 G 3 B
2 B 3 R
1 R 3 R
2 R 3 R
1 B 3 R
1 B 3 G
1 R 3 B
2 R 3 B
2 B 3 B
1 R 2 R
2 G 3 G
2 B 3 G
1 G 2 G
1 G 3 G
1 G 2 R
2 G 3 R
1 G 2 B
1 R 3 G

output:

0

result:

ok answer is '0'

Test #14:

score: 0
Accepted
time: 159ms
memory: 69436kb

input:

9 176
2 G 3 R
1 G 4 R
4 B 5 G
5 G 7 B
8 G 9 R
1 R 4 B
4 B 8 B
1 B 5 B
6 B 8 B
2 G 6 G
2 B 8 B
1 R 9 B
2 B 8 G
1 G 4 G
1 B 3 R
3 R 7 B
7 B 8 B
5 B 6 R
6 R 9 R
5 R 7 G
4 G 9 B
3 G 9 G
1 R 6 R
1 G 3 G
3 R 6 R
4 G 5 R
4 G 7 B
2 G 8 B
1 B 9 R
3 G 8 R
3 R 5 G
5 R 9 R
3 G 5 R
1 R 4 R
4 B 7 B
3 R 9 R
2 B 4 ...

output:

0

result:

ok answer is '0'

Test #15:

score: -100
Wrong Answer
time: 159ms
memory: 87648kb

input:

22 38
12 G 17 B
1 G 20 R
9 B 20 G
15 G 19 B
11 B 22 R
13 R 19 G
21 R 22 B
4 G 11 B
9 R 10 R
8 R 15 B
1 G 16 B
13 R 19 B
1 G 11 G
9 R 11 G
7 B 8 G
9 R 18 G
3 G 13 B
3 G 14 B
10 R 16 R
14 G 16 B
3 R 9 R
18 R 21 B
11 B 20 G
1 G 10 G
2 R 16 G
6 B 20 R
4 B 20 B
8 G 10 B
7 R 11 R
16 G 18 G
3 B 8 B
11 R 22...

output:

381690669

result:

wrong answer expected '258518109', found '381690669'