QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#107973#2827. AutobiographyHuangHanShengTL 3ms10012kbC++201.4kb2023-05-23 12:07:252023-05-23 12:07:26

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 3ms
memory: 10012kb

input:

5 4
bbobo
1 3
2 3
3 4
4 5
4 6
bobo
1 2
1 3
1 4
2 3
2 4
3 4
4 0
bobo

output:

2
4
0

result:

ok 3 lines

Test #2:

score: -100
Time Limit Exceeded

input:

4 4
oobo
2 3
4 1
4 3
3 1
4 3
obob
1 4
2 3
1 2
4 4
obob
3 1
2 3
2 1
1 4
4 3
bboo
2 4
4 1
3 4
4 3
bbbo
1 4
1 3
4 2
4 4
obbo
3 4
2 4
2 3
3 1
4 3
bobo
2 3
4 3
1 4
4 3
obbb
3 4
4 2
1 4
4 5
bobo
4 1
2 1
3 1
4 3
2 4
4 4
obbo
3 4
3 1
2 3
1 4
4 3
bobb
4 2
4 1
2 3
4 3
obbo
3 1
3 2
1 2
4 4
ooob
2 1
3 1
3 4
1 4...

output:

0
1
1
0
0
1
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
4
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
1
0
0
0
0
0
0
4
1
0
0
0
0
4
0
0
0
0
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
...

result: