QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#294469#4824. Bracket-and-bar Sequencesucup-team1123#0 0ms3792kbC++235.3kb2023-12-30 13:58:402023-12-30 13:58:40

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3792kb

input:

encode
3
1
(|)
4
((((|)|)|)|)
5
(|(|))((|(|))|)

output:

6
201
1719

input:

decode
3
1
6
4
201
5
1719

output:

(|)
((((|)|)|)|)
(|(|))((|(|))|)

result:

ok 3 lines

Test #2:

score: 100
Accepted
time: 0ms
memory: 3776kb

input:

encode
1
1
(|)

output:

6

input:

decode
1
1
6

output:

(|)

result:

ok single line: '(|)'

Test #3:

score: 100
Accepted
time: 0ms
memory: 3584kb

input:

encode
3
2
((|)|)
1
(|)
2
(|(|))

output:

21
6
18

input:

decode
3
2
21
1
6
2
18

output:

((|)|)
(|)
(|(|))

result:

ok 3 lines

Test #4:

score: 0
Stage 1: Program answer Memory Limit Exceeded

input:

encode
1000
3
(|)(|)(|)
3
(|)(|(|))
3
(|)((|)|)
3
(|(|))(|)
3
(|(|)(|))
3
(|(|(|)))
3
(|((|)|))
3
((|)|)(|)
3
((|)|(|))
3
((|)(|)|)
3
((|(|))|)
3
(((|)|)|)
4
(|)(|)(|)(|)
4
(|)(|)(|(|))
4
(|)(|)((|)|)
4
(|)(|(|))(|)
4
(|)(|(|)(|))
4
(|)(|(|(|)))
4
(|)(|((|)|))
4
(|)((|)|)(|)
4
(|)((|)|(|))
4
(|)((|)...

output:

546
168
195
180

input:


output:


result: