QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#691027#3079. Joining The Bricks TogetherxiebohangAC ✓631ms3188kbC++171.2kb2024-10-31 09:28:492024-10-31 09:28:49

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 631ms
memory: 3188kb

input:

44279
1
1 B
1
1 W
2
1 B
1 W
2
1 W
1 W
3
1 B
1 B
1 W
3
1 W
1 B
1 W
3
1 B
1 W
1 W
3
1 W
1 W
1 W
4
1 B
1 B
1 B
1 W
4
1 W
1 B
1 B
1 W
4
1 B
1 W
1 B
1 W
4
1 W
1 W
1 B
1 W
4
1 B
1 B
1 W
1 W
4
1 W
1 B
1 W
1 W
4
1 B
1 W
1 W
1 W
4
1 W
1 W
1 W
1 W
5
1 B
1 B
1 B
1 B
1 W
5
1 W
1 B
1 B
1 B
1 W
5
1 B
1 W
1 B
1 B
...

output:

1
1
1
2
1
1
1
3
1
2
2
1
1
1
1
4
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
5
1
2
2
2
2
3
3
1
1
3
3
2
2
2
2
1
1
2
2
2
1
2
2
1
1
1
1
1
1
1
1
6
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
7
1
2
2
1
2
1
1
2
2
1
1
2
1
3
3
1
1
1
1
3
1
4
...

result:

ok 44279 lines

Test #2:

score: 0
Accepted
time: 0ms
memory: 1652kb

input:

3
3
1 B
3 W
2 B
4
3 W
3 B
9 W
1 B
2
2 W
3 W

output:

2
3
5

result:

ok 3 lines