QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#96078#5093. 会议LeafSeek0 2ms3808kbC++142.4kb2023-04-13 09:56:112023-04-13 09:56:14

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 0
Wrong Answer

Test #1:

score: 2
Accepted
time: 2ms
memory: 3692kb

input:

1
100
0 4
0 4
0 1
1 1
0 2
0 2
1 3
1 2
0 2
1 5
0 2
0 3
0 3
0 4
1 8
1 9
1 6
0 1
0 2
0 1
1 11
1 12
0 2
1 13
1 14
1 4
0 2
1 15
0 3
1 16
0 4
0 2
0 2
1 17
1 19
1 7
0 3
1 20
0 4
1 21
0 4
1 22
0 1
0 3
1 23
1 24
0 3
1 25
0 1
0 4
1 26
1 27
0 4
0 1
1 29
1 28
0 4
1 30
0 1
0 3
0 4
0 4
0 3
0 2
1 34
0 4
0 4
0 3
1 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 4
1 4
1 4
0 -1
0 -1
0 -1
1 2
1 2
1 2
1 2
1 2
1 2
1 2
0 -1
1 2
1 2
1 2
0 -1
1 2
0 -1
1 2
0 -1
1 2
1 2
1 2
0 -1
1 2
0 -1
0 -1
0 -1
1 4
0 -1
1 2
1 2
1 2
0 -1
0 -1
0 -1
1 4
0 -1
1 4
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 4
0 ...

result:

ok both questions correct

Test #2:

score: 2
Accepted
time: 2ms
memory: 3680kb

input:

1
100
0 1
0 1
0 1
0 2
1 3
0 1
0 1
1 5
0 2
0 2
0 2
1 9
0 1
1 1
0 2
0 2
1 11
1 10
1 12
1 8
1 4
1 6
0 2
1 13
0 1
1 14
0 2
1 15
0 1
0 2
1 16
0 1
0 2
1 19
1 18
0 1
1 20
1 17
0 1
1 21
0 1
0 2
1 22
1 2
0 1
1 24
0 2
1 25
0 2
1 26
0 1
0 2
0 1
1 29
1 28
1 27
0 2
1 30
0 1
1 31
0 1
1 32
0 1
1 33
0 2
0 1
1 35
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
0 -1
1 2
0 -1
1 1
0 -1
1 2
1 2
1 2
1 2
1 2
0 -1
1 1
0 -1
1 2
0 -1
1 1
0 -1
1 2
0 -1
1 1
0 -1
1 2
0 -1
1 2
0 -1
1 2
0 -1
1 2
0 -1
1 1
0 -1
1 1
0 -1
1 2
1 2
1 2
1 2
1 2
1 2
1 2
1 2
1 2
1 2
1 2
1 2
...

result:

ok both questions correct

Test #3:

score: 2
Accepted
time: 1ms
memory: 3788kb

input:

1
100
0 3
0 2
0 3
1 2
0 1
0 2
0 1
0 1
1 7
1 3
0 2
1 8
1 4
0 1
1 9
1 5
0 2
0 1
0 1
0 3
0 4
0 4
1 15
1 10
0 3
0 3
1 17
1 16
0 1
0 3
1 18
1 13
0 1
1 20
0 3
1 21
1 12
0 2
0 2
1 23
0 2
0 3
0 2
1 24
0 1
0 2
0 1
0 1
0 3
1 27
0 1
1 32
0 1
0 3
0 1
1 35
1 28
1 34
0 2
1 30
1 31
0 2
0 1
0 2
0 1
0 1
0 1
1 37
0 2...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 3
0 -1
1 3
1 3
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #4:

score: 2
Accepted
time: 2ms
memory: 3808kb

input:

1
100
0 3
0 2
0 1
1 3
0 1
1 2
0 1
1 5
0 2
1 6
0 1
0 2
1 8
0 1
1 9
0 4
0 1
1 10
1 11
0 2
1 12
1 4
0 3
1 13
0 1
1 14
0 1
1 15
0 1
0 4
0 4
0 1
1 19
0 2
0 1
0 1
1 21
0 2
0 1
0 1
0 1
1 25
1 23
1 24
0 1
1 27
1 26
1 16
1 18
0 3
0 1
0 1
0 2
0 1
1 30
0 2
0 1
1 28
1 34
0 1
1 32
0 1
1 35
1 29
1 36
1 7
0 1
0 1
...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
1 1
0 -1
1 1
1 1
1 1
0 -1
1 1
1 1
1 1
0 -1
1 1
0 -1
1 3
0 -1
1 1
0 -1
1 1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
1 1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #5:

score: 2
Accepted
time: 2ms
memory: 3748kb

input:

1
100
0 5
0 2
0 5
1 3
0 2
1 2
0 3
1 4
0 1
0 6
0 7
1 6
1 8
0 6
1 9
0 3
0 2
1 10
1 11
0 2
1 5
1 1
0 2
0 4
0 5
1 15
1 14
1 12
0 5
0 2
1 16
0 6
0 1
1 19
0 3
0 5
0 7
1 21
1 22
0 2
0 1
1 24
1 23
0 5
1 7
1 17
1 20
1 25
0 3
1 26
0 5
0 6
0 1
1 27
1 28
0 3
0 3
1 30
1 31
0 1
0 5
0 2
1 33
1 34
0 1
1 35
1 29
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 5
0 -1
1 5
0 -1
1 2
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 2
0 -1
0 -1
0 -1
1 2
0 -1
0 -1
0 -1
1 2
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 ...

result:

ok both questions correct

Test #6:

score: 2
Accepted
time: 2ms
memory: 3788kb

input:

1
100
0 1
0 3
0 3
1 3
0 8
1 4
0 5
1 5
0 3
0 5
1 7
1 6
0 5
0 4
0 8
1 9
0 1
1 10
0 6
0 1
1 13
1 12
1 11
1 8
0 7
1 14
0 3
0 4
0 1
1 17
1 15
1 16
0 1
0 7
1 18
1 19
0 8
1 20
0 6
1 21
0 4
0 6
1 22
0 3
0 3
1 24
1 25
0 1
0 7
1 26
0 4
1 28
1 27
0 2
0 6
1 29
0 2
1 30
0 5
0 6
0 4
1 34
1 33
1 32
0 7
0 2
0 1
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
0 -1
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
1 3
0 -1
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 3
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #7:

score: 2
Accepted
time: 2ms
memory: 3660kb

input:

1
100
0 5
0 5
0 7
1 1
0 5
1 2
0 2
0 9
1 6
1 4
0 10
0 6
1 8
1 5
0 7
1 9
0 4
0 6
0 10
0 1
0 5
1 12
0 3
1 11
0 6
0 6
1 15
1 13
0 8
1 17
1 16
0 7
1 14
1 18
1 7
0 1
0 13
0 5
1 22
0 9
1 23
1 20
0 4
0 11
1 24
1 25
1 10
1 21
0 2
1 26
0 13
0 10
0 4
0 2
1 28
1 29
1 30
1 27
0 1
1 31
0 2
1 32
0 13
1 33
0 9
1 34...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 5
1 5
1 5
0 -1
1 5
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
1 7...

result:

ok both questions correct

Test #8:

score: 2
Accepted
time: 0ms
memory: 3752kb

input:

1
100
0 5
0 12
0 2
1 2
0 1
0 2
1 1
0 1
0 7
1 5
0 3
1 4
1 8
0 6
0 1
1 9
1 3
1 7
0 4
0 3
0 2
0 4
0 1
1 13
0 1
1 14
1 12
0 9
1 17
1 15
0 7
0 2
0 1
0 6
0 1
0 4
1 21
0 1
0 10
1 24
1 22
1 23
1 11
0 1
1 20
0 8
0 10
0 2
0 1
1 27
1 30
0 4
1 31
1 28
0 6
1 32
0 13
1 29
1 16
1 18
1 26
0 12
1 34
1 6
1 10
0 10
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 5
0 -1
0 -1
0 -1
0 -1
0 -1
1 2
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
1 1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
0 -1
1 1
0 -1
1 1
0 -1
1 1
1 1
1 1
0 -1
0 -1
0 -1
1 1
1 1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #9:

score: 2
Accepted
time: 2ms
memory: 3792kb

input:

1
100
0 14
0 14
0 14
1 3
0 7
1 4
0 18
0 21
0 18
1 7
1 5
0 17
0 24
0 11
1 6
0 7
0 8
0 3
1 1
1 13
1 10
0 7
0 3
0 24
0 19
0 9
0 13
0 1
1 20
0 17
1 21
0 24
0 1
1 16
0 25
1 22
1 14
1 24
0 16
0 10
1 25
1 15
0 3
0 6
1 9
1 27
1 8
1 18
0 14
0 24
1 29
1 30
1 28
1 12
0 9
1 31
1 23
0 2
0 15
1 32
0 1
1 34
0 10
1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 14
1 14
1 14
1 14
1 14
1 14
1 14
0 -1
0 -1
0 -1
1 14
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #10:

score: 2
Accepted
time: 2ms
memory: 3700kb

input:

1
100
0 1
0 1
0 16
1 2
0 19
0 4
1 5
0 19
0 7
1 7
0 7
0 15
1 8
0 9
0 5
1 10
1 9
0 3
0 12
1 12
1 11
0 5
0 8
0 9
1 14
0 1
1 16
0 2
0 3
1 19
0 5
1 18
1 20
0 10
0 4
1 21
1 22
1 4
1 3
0 9
0 1
1 23
0 11
0 2
0 6
0 12
0 17
0 13
1 25
0 11
1 31
0 8
0 17
0 5
0 8
0 15
0 10
0 3
1 37
0 16
0 5
0 6
0 5
1 42
0 12
1 4...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
1 1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1...

result:

ok both questions correct

Test #11:

score: 2
Accepted
time: 2ms
memory: 3712kb

input:

1
100
0 2
0 4
0 4
1 3
0 4
0 4
0 3
1 6
1 2
0 3
1 7
1 1
0 4
0 4
0 2
0 3
0 4
1 8
1 10
0 3
1 9
0 4
0 3
0 3
0 4
0 4
0 3
1 15
0 4
1 14
1 16
1 12
0 4
1 5
1 21
1 4
0 3
0 4
0 4
0 4
0 3
1 23
1 24
0 3
0 4
0 2
1 26
1 27
0 4
1 30
0 4
0 4
0 3
1 22
1 33
1 32
1 31
1 28
0 4
1 34
1 11
1 13
1 18
0 2
0 4
0 3
0 2
1 35
0...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 2
0 -1
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
0 -1
1 3
0 -1
1 4
1 4
1 4
0 -1
1 3
1 3
1 3
0 -1
0 -1
0 -1
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
...

result:

ok both questions correct

Test #12:

score: 2
Accepted
time: 2ms
memory: 3792kb

input:

1
100
0 4
0 2
0 1
1 2
0 2
0 1
0 4
0 1
1 5
0 3
1 6
1 7
0 1
1 9
0 1
1 10
0 2
0 2
0 2
0 1
0 4
1 12
0 4
1 11
1 13
0 2
0 3
1 18
1 15
1 14
0 2
1 19
0 4
0 3
0 3
1 20
1 21
1 16
0 4
1 23
0 3
1 24
0 4
0 4
0 3
1 17
1 3
0 1
1 28
1 1
0 3
1 26
1 4
1 29
1 22
1 27
0 1
0 2
1 31
1 30
0 3
0 3
0 1
1 34
0 2
1 32
0 2
0 1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 4
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 2
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #13:

score: 2
Accepted
time: 2ms
memory: 3712kb

input:

1
100
0 4
0 3
0 4
0 3
0 4
1 1
0 4
1 6
0 4
1 4
0 4
1 2
1 7
0 4
1 9
1 3
0 3
0 2
1 11
1 10
0 4
0 4
0 4
0 3
0 3
1 12
1 13
1 16
0 1
0 4
1 17
1 14
0 4
0 3
0 4
0 4
0 4
0 2
1 20
1 18
1 19
0 3
0 1
1 26
0 2
1 27
1 25
0 3
1 21
0 3
1 29
0 2
1 23
1 22
1 28
1 15
1 5
1 30
0 3
1 31
0 1
1 32
0 4
1 33
0 3
1 34
0 4
1 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 4
0 -1
1 4
0 -1
1 4
0 -1
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
1 4
0 -1
1 4
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #14:

score: 2
Accepted
time: 2ms
memory: 3692kb

input:

1
100
0 7
0 7
0 6
0 6
0 9
1 5
0 9
1 6
0 7
0 7
1 8
0 7
0 5
1 7
1 1
0 9
0 4
0 8
1 11
0 8
0 9
1 13
0 4
1 14
1 12
0 6
0 8
1 16
0 4
1 19
1 15
0 4
1 17
1 4
1 10
1 18
1 20
1 3
0 7
0 9
1 22
1 21
0 7
1 23
0 8
0 9
0 9
1 26
0 5
0 7
0 4
0 7
1 28
0 8
0 9
1 29
1 30
0 4
1 24
1 32
0 8
0 8
1 34
0 9
1 35
1 31
0 9
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 7
1 7
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
1 7
1 7
1 7
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
0 -1
0 -1
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #15:

score: 2
Accepted
time: 1ms
memory: 3764kb

input:

1
100
0 8
0 7
0 7
1 3
0 9
0 9
1 4
1 5
0 7
0 8
1 7
0 8
1 8
1 1
0 9
0 7
0 7
0 6
0 4
0 7
1 12
1 9
1 10
0 5
1 15
1 6
1 13
0 3
1 2
1 16
0 5
0 6
1 17
1 11
0 8
1 19
0 9
1 20
0 8
0 8
1 22
1 21
0 9
1 23
0 7
0 7
0 9
1 24
1 25
1 26
0 9
1 27
0 5
1 28
0 7
1 29
0 7
0 8
1 31
1 18
0 6
1 32
0 8
1 33
0 6
0 9
1 34
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 8
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
0 -1
1 7
0 -1
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
1 7
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
1 7
1 7
0 -1
0 -1
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #16:

score: 2
Accepted
time: 2ms
memory: 3752kb

input:

1
100
0 13
0 7
0 15
1 2
0 14
0 13
1 1
0 10
1 4
0 10
1 7
1 6
0 9
1 8
0 4
1 9
0 13
1 10
0 12
0 15
1 11
0 7
1 12
0 9
1 14
0 11
0 8
1 16
0 14
1 17
1 15
1 5
0 10
1 18
0 13
1 19
0 13
1 3
0 15
1 21
0 14
1 22
0 7
1 23
0 13
0 15
1 24
1 25
0 14
1 26
0 7
1 27
0 2
0 15
1 28
1 20
0 15
0 15
1 31
1 30
0 11
1 32
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 13
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 13
0 -1
0 -1
0 -1
1 15
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
0 -1
1 13
0 -1
0 ...

result:

ok both questions correct

Test #17:

score: 2
Accepted
time: 1ms
memory: 3716kb

input:

1
100
0 15
0 12
0 15
0 13
0 12
1 2
0 14
0 15
1 3
0 14
0 13
1 8
0 4
0 7
1 10
1 9
0 13
1 11
1 1
1 4
1 12
0 14
1 5
0 15
0 15
0 11
0 13
0 15
0 12
0 12
0 12
0 14
0 14
0 14
1 15
1 22
1 21
1 19
1 17
1 14
0 15
1 20
0 13
0 13
0 8
1 27
0 7
1 29
0 11
0 7
1 30
1 28
1 26
1 6
0 12
0 11
1 33
0 13
0 12
1 32
1 18
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 15
0 -1
1 15
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 14
0 -1
1 15
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #18:

score: 2
Accepted
time: 2ms
memory: 3656kb

input:

1
100
0 6
0 23
0 26
1 2
0 18
0 22
0 20
0 29
0 17
1 7
0 23
1 9
0 22
1 1
1 6
1 4
0 20
0 24
1 12
0 29
0 23
0 28
0 27
0 16
0 27
0 27
0 28
0 25
0 25
0 30
1 19
0 15
1 17
1 16
1 13
0 27
1 25
0 30
1 15
0 26
0 24
0 25
1 23
1 26
1 21
1 18
0 11
1 20
1 3
0 17
0 12
1 31
0 23
1 32
0 18
1 33
1 34
0 30
0 19
1 36
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 6
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 ...

result:

ok both questions correct

Test #19:

score: 2
Accepted
time: 1ms
memory: 3700kb

input:

1
100
0 23
0 20
0 29
0 24
0 26
0 23
0 17
1 4
0 26
0 16
1 8
0 26
1 6
1 10
0 30
1 9
0 19
1 1
1 7
1 5
1 11
0 27
1 13
0 20
1 14
1 12
0 24
0 23
1 16
1 15
0 20
0 30
0 26
1 17
1 18
0 15
0 24
1 20
1 21
0 28
0 14
1 23
0 27
0 16
0 19
1 25
0 17
0 30
0 27
0 16
1 27
1 30
1 24
1 26
1 29
0 23
1 31
0 24
0 29
0 22
0...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 23
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 20
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #20:

score: 2
Accepted
time: 2ms
memory: 3688kb

input:

1
100
0 43
0 47
0 31
0 38
1 1
0 44
0 36
1 6
1 3
1 2
0 46
0 49
0 41
0 16
1 9
0 40
1 11
1 4
1 8
0 49
1 12
0 44
0 41
0 46
1 15
0 34
1 14
0 19
0 21
0 50
0 27
0 42
1 21
1 18
0 36
0 41
0 42
0 26
0 36
0 49
0 3
1 24
1 25
1 22
0 36
0 29
0 49
0 19
0 49
1 31
1 29
1 30
1 10
0 49
0 42
1 35
0 46
1 5
0 20
1 37
1 1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 43
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #21:

score: 2
Accepted
time: 2ms
memory: 3692kb

input:

1
100
0 28
0 44
0 35
1 3
0 46
1 1
0 42
1 2
0 48
0 49
1 6
0 40
1 7
0 41
0 43
0 43
1 11
0 49
0 45
1 13
0 26
1 9
1 10
1 12
1 14
0 44
0 14
1 16
1 15
1 5
0 35
1 17
0 32
1 18
0 47
1 19
0 30
0 46
0 47
1 21
1 22
0 28
0 45
0 44
1 24
0 40
0 37
0 41
1 27
1 26
1 20
1 28
0 15
1 29
1 23
0 43
1 25
0 33
0 46
1 32
1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 28
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #22:

score: 2
Accepted
time: 2ms
memory: 3688kb

input:

1
100
0 9
0 10
0 9
0 9
0 10
0 9
1 2
0 10
0 7
0 10
1 6
1 3
1 8
0 9
1 10
0 9
0 10
0 8
1 13
0 10
0 10
1 14
0 7
1 16
1 1
0 9
1 12
1 7
1 5
0 9
1 9
1 11
1 4
1 15
0 7
0 10
0 9
0 10
0 10
1 19
1 22
1 23
1 20
1 18
0 10
0 10
1 24
0 8
1 21
1 17
0 10
0 10
1 28
1 26
0 9
1 29
0 9
0 10
1 31
1 30
0 10
0 10
0 10
0 7
...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 9
0 -1
1 9
1 9
1 9
1 9
1 9
1 9
1 9
0 -1
0 -1
0 -1
1 10
0 -1
1 10
0 -1
1 10
0 -1
1 10
1 10
1 10
1 10
1 10
1 10
1 10
1 10
1 10
0 -1
1 9
1 9
1 9
1 9
1 9
1 9
1 9
0 -1
1 9
0 -1
0 -1
0 -1
1 9
1 9
1 9
1 9
1 9
0 -1
1 9
0 -1
0 -1
0 -1
1 1...

result:

ok both questions correct

Test #23:

score: 2
Accepted
time: 2ms
memory: 3760kb

input:

1
100
0 1
0 3
0 1
1 2
0 2
1 4
0 1
0 2
0 3
1 6
1 5
0 1
1 1
0 4
1 9
0 4
0 1
1 11
1 10
0 2
1 12
0 1
0 3
1 13
1 3
1 14
0 3
1 15
0 3
1 16
0 4
0 4
0 2
0 4
0 3
1 18
0 4
1 22
1 19
0 1
0 2
0 3
0 2
1 23
1 24
1 21
1 26
1 20
0 3
1 27
0 4
1 28
0 4
1 29
1 17
0 1
1 30
0 2
0 2
0 2
0 4
0 3
0 1
0 4
0 1
0 3
0 2
1 39
1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
0 -1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
1 1
0 -1
1 1
0 -1
1 1
0 -1
1 1
0 -1
1 1
1 1
1 1
0 -1
1 3
0 -1
1 3
0 -1
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 3
0 -1
0 -...

result:

ok both questions correct

Test #24:

score: 2
Accepted
time: 0ms
memory: 3656kb

input:

1
100
0 16
0 18
0 14
0 13
0 15
1 2
1 3
0 17
1 4
0 14
0 14
1 8
1 6
0 16
0 18
0 18
0 18
1 10
0 15
0 17
1 11
1 9
0 16
1 15
0 12
0 16
0 15
1 1
0 12
1 19
1 17
0 13
1 20
1 7
1 14
1 18
0 16
0 16
1 22
1 21
1 5
1 12
0 18
1 23
0 15
1 24
0 18
0 17
1 25
1 26
0 16
1 27
0 18
0 18
0 17
1 28
0 12
1 29
1 31
0 18
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 16
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 15
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 15
0 -1
0...

result:

ok both questions correct

Test #25:

score: 2
Accepted
time: 2ms
memory: 3796kb

input:

1
100
0 36
0 40
0 37
1 3
0 40
0 32
0 37
0 35
0 39
0 39
1 4
1 7
1 2
0 37
1 10
0 37
1 11
1 6
1 1
0 39
0 40
0 36
1 13
0 36
0 33
1 16
0 39
1 17
0 34
0 38
1 18
1 19
1 14
1 8
0 36
1 20
0 37
1 21
1 12
1 9
0 39
0 38
0 37
0 39
1 23
1 25
0 38
0 39
1 27
0 40
0 38
0 36
1 30
0 34
0 37
1 31
1 32
0 37
0 38
0 37
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 36
0 -1
0 -1
0 -1
1 40
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 39
1 39
1 39
0 -1
1 39
0 -1
0 -1
0 -1
1 39
0 -1
0 -1
0 -1
0 -1
0 -1
1 39
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #26:

score: 2
Accepted
time: 2ms
memory: 3660kb

input:

1
100
0 99
0 107
0 108
0 106
0 104
0 103
0 106
1 2
0 108
1 8
0 110
1 5
0 110
0 109
0 110
1 12
1 10
0 109
1 13
0 109
0 97
0 108
1 15
1 9
0 109
0 108
1 18
0 100
1 19
0 99
1 1
0 82
0 106
0 107
0 101
0 108
0 108
1 24
0 109
1 26
0 103
1 28
1 25
0 79
1 29
0 110
1 30
0 109
0 109
1 32
1 31
0 110
0 109
0 108...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 99
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #27:

score: 2
Accepted
time: 2ms
memory: 3748kb

input:

1
100
0 30
0 28
0 30
0 30
0 30
0 27
0 30
0 28
1 2
0 26
1 9
1 1
0 29
1 10
1 5
0 28
1 6
1 8
0 28
1 3
1 12
0 28
1 13
0 30
1 14
1 7
0 26
0 30
1 16
0 28
1 15
1 17
0 29
1 18
0 30
1 11
0 29
0 30
1 20
0 30
1 22
1 21
0 30
1 23
0 26
1 24
0 30
1 25
0 30
0 29
1 27
1 26
0 29
1 28
0 30
1 29
0 28
0 30
1 31
0 30
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 30
0 -1
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
0 -1
1 30
1 30
1 30
0 -1
1 30
0 -1
1 30
1 30
1 30
0 -1
0 -1
0 -1
0 -1
0 -1
1 28
0 -1
0 -1
0 -1
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1 30
1...

result:

ok both questions correct

Test #28:

score: 2
Accepted
time: 2ms
memory: 3788kb

input:

1
100
0 15
0 20
0 2
1 2
0 12
1 3
0 4
1 5
0 1
1 4
0 9
0 8
0 12
1 9
1 8
0 1
1 10
1 7
0 1
0 5
0 2
0 10
1 11
1 14
0 5
0 8
0 10
0 14
0 14
0 4
1 18
1 16
1 15
1 20
1 12
1 6
1 13
0 2
1 21
1 19
0 3
0 1
1 23
1 22
0 2
1 24
0 21
1 1
0 10
1 26
0 2
0 5
0 2
1 27
1 29
1 28
0 4
1 30
0 2
1 31
0 1
1 32
0 1
1 33
0 3
1 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 15
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 ...

result:

ok both questions correct

Test #29:

score: 2
Accepted
time: 2ms
memory: 3692kb

input:

1
100
0 1
0 3
0 3
0 3
1 2
1 4
0 2
1 3
0 1
1 6
0 4
1 5
0 3
1 7
0 4
1 9
0 4
1 10
0 7
1 11
0 2
1 12
0 2
0 1
0 1
1 14
1 13
0 1
0 2
0 2
1 18
1 16
0 2
0 2
1 20
0 5
0 1
0 1
1 22
1 17
1 21
1 19
0 2
0 4
1 24
0 7
0 2
1 27
1 26
0 1
0 1
0 1
1 29
1 30
0 9
1 31
1 25
1 23
0 1
0 4
0 2
1 33
1 34
0 3
0 1
1 36
1 35
1 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
0 -1
1 3
1 3
1 3
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
1 1
1 1
1 1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
1 1
1 1
0 -1
1 1
0 -1
0 -1
0 -1
1 1
1...

result:

ok both questions correct

Test #30:

score: 2
Accepted
time: 2ms
memory: 3756kb

input:

1
100
0 1
0 3
0 10
0 1
0 2
0 2
0 1
0 2
1 8
0 8
1 1
0 2
1 6
0 1
0 4
0 1
0 1
1 13
1 12
1 14
0 1
0 7
1 15
0 2
1 17
1 16
1 5
0 2
0 1
1 19
1 10
1 2
1 7
0 2
0 6
1 21
0 13
0 1
1 22
1 23
0 1
1 24
0 1
0 1
0 1
1 27
1 26
0 2
0 3
1 29
1 28
0 4
1 30
1 25
0 4
1 31
1 11
1 3
1 9
1 18
0 2
1 32
0 1
1 4
0 1
0 6
0 2
1 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -...

result:

ok both questions correct

Test #31:

score: 2
Accepted
time: 2ms
memory: 3788kb

input:

1
100
0 13
0 9
0 27
1 3
0 12
0 8
1 5
0 6
0 8
1 6
1 7
0 86
0 22
1 9
0 8
1 8
1 2
0 48
1 4
1 11
0 10
0 50
1 12
0 36
1 14
0 6
0 9
1 16
0 17
1 13
0 12
0 6
0 2
0 8
1 18
1 19
0 8
1 22
1 17
0 3
1 23
0 8
1 21
0 26
1 20
1 24
0 6
0 7
1 27
0 5
0 11
0 69
0 7
0 15
0 1
1 32
1 29
0 1
1 34
1 33
0 17
0 1
1 36
1 26
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 13
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #32:

score: 2
Accepted
time: 0ms
memory: 3756kb

input:

1
100
0 10
0 11
0 32
0 4
0 3
1 2
0 7
0 32
0 5
1 7
1 1
1 5
0 28
0 44
1 9
1 6
1 4
1 10
0 24
0 16
0 2
0 57
1 12
0 7
0 7
1 14
0 7
1 17
0 9
1 18
0 15
0 24
0 4
0 72
0 6
0 4
0 15
1 22
0 20
0 27
0 2
0 25
1 26
0 6
0 11
1 31
1 20
1 21
0 25
0 40
0 7
0 41
1 32
1 25
1 34
1 35
0 8
1 15
0 4
1 37
1 11
1 8
0 8
0 50
...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 10
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #33:

score: 2
Accepted
time: 2ms
memory: 3776kb

input:

1
100
0 26
0 10
0 22
1 1
0 2
0 23
0 17
0 32
1 5
0 19
1 8
0 9
1 9
0 8
1 10
1 6
0 32
1 3
1 4
0 6
1 12
1 7
0 2
0 6
0 5
0 8
1 14
0 12
1 13
1 16
0 17
1 18
1 15
1 17
0 11
1 19
0 43
0 8
0 5
0 19
0 26
0 3
1 21
0 9
0 1
0 21
0 25
0 17
1 28
0 4
0 19
0 59
1 33
0 4
0 17
1 26
1 30
0 11
0 2
0 7
1 27
0 10
1 39
0 17...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 26
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 32
0 -1
1 32
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #34:

score: 2
Accepted
time: 2ms
memory: 3696kb

input:

1
100
0 4
0 6
0 4
1 2
0 3
0 4
1 3
1 5
0 6
1 6
0 7
0 7
1 7
0 6
1 9
1 1
0 8
1 10
0 3
0 6
0 5
0 5
1 14
1 12
0 4
1 15
1 11
0 7
0 1
1 16
1 17
1 13
0 3
1 18
0 5
1 19
0 4
1 20
0 7
0 1
0 8
1 22
1 23
1 21
0 4
1 24
0 8
0 1
0 4
1 26
1 25
0 5
1 27
1 28
0 7
1 29
0 5
0 1
1 31
1 30
0 9
0 9
1 32
0 5
0 6
0 9
0 3
0 1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 4
0 -1
1 4
1 4
1 4
1 4
1 4
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 3
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
0 -1
0 -1
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #35:

score: 2
Accepted
time: 1ms
memory: 3688kb

input:

1
100
0 2
0 2
0 21
0 7
1 4
0 4
0 7
1 5
0 3
1 1
0 43
1 8
0 17
0 7
1 10
0 6
1 2
0 3
1 3
1 11
1 12
0 2
1 13
1 9
0 13
1 14
0 2
1 6
0 48
0 16
0 9
0 2
0 20
1 18
1 20
1 17
0 14
1 21
1 15
1 16
0 5
0 5
1 22
0 4
1 24
0 14
1 23
1 25
0 9
0 19
0 3
1 26
0 3
1 27
0 36
1 30
1 28
1 19
0 8
0 4
1 31
1 32
0 4
0 27
1 33...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 2
1 2
1 2
0 -1
1 2
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
...

result:

ok both questions correct

Test #36:

score: 2
Accepted
time: 2ms
memory: 3788kb

input:

1
100
0 5
0 9
0 17
1 2
0 2
1 3
0 5
1 4
0 7
0 15
1 5
1 7
0 15
0 9
1 8
1 9
0 2
0 9
0 11
0 16
0 17
1 12
1 11
0 13
0 4
0 15
0 15
0 11
1 19
0 15
1 20
0 11
0 5
1 22
0 5
1 23
1 15
1 14
1 21
0 41
0 13
0 5
1 26
0 22
0 1
0 14
1 27
1 28
0 1
0 2
0 11
0 8
0 23
0 7
1 33
1 29
1 30
0 32
1 36
1 25
1 31
1 18
0 52
0 4...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 5
0 -1
0 -1
0 -1
0 -1
0 -1
1 5
1 5
1 5
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
...

result:

ok both questions correct

Test #37:

score: 2
Accepted
time: 2ms
memory: 3692kb

input:

1
100
0 8
0 25
0 15
1 1
0 6
0 6
1 5
0 47
1 6
0 35
0 11
0 19
0 6
1 8
0 13
0 10
0 31
0 1
0 16
0 9
0 16
0 25
1 12
0 4
0 11
0 22
0 13
0 17
1 21
1 22
0 19
1 14
1 16
1 7
1 23
1 17
0 17
1 25
0 21
1 10
1 20
0 1
1 9
1 13
0 11
0 11
1 29
1 15
1 11
1 26
1 2
1 28
1 18
0 4
0 2
0 8
1 30
1 32
0 3
1 33
1 31
0 11
0 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 8
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 ...

result:

ok both questions correct

Test #38:

score: 2
Accepted
time: 2ms
memory: 3768kb

input:

1
100
0 12
0 4
0 1
1 3
0 5
0 8
0 8
0 1
0 6
1 5
1 4
0 22
1 6
0 3
0 2
0 15
1 12
1 2
0 5
0 12
1 14
0 5
1 15
1 8
1 9
1 7
0 2
1 13
0 6
1 16
1 1
0 6
0 3
0 1
0 3
1 21
0 12
0 2
0 1
0 10
1 23
1 22
1 24
1 10
1 18
0 1
0 17
0 15
1 28
1 26
1 27
1 17
1 11
0 8
1 29
1 19
0 1
0 5
0 12
1 31
0 10
0 3
1 33
0 17
0 4
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 12
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #39:

score: 2
Accepted
time: 2ms
memory: 3756kb

input:

1
100
0 1
0 11
0 1
1 1
0 9
1 4
0 16
1 5
0 6
0 9
1 2
1 7
0 20
1 8
0 3
1 9
0 10
1 6
0 3
0 1
0 1
1 11
1 12
1 13
0 1
1 14
0 8
1 15
0 5
1 16
0 1
1 17
0 2
1 18
0 5
0 1
1 19
0 5
1 20
0 3
1 22
1 21
0 15
0 1
1 23
0 13
1 24
1 25
0 5
0 11
1 26
1 27
0 3
1 10
0 23
0 2
0 2
0 8
0 12
1 32
0 5
0 9
0 3
1 30
1 34
0 4
...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
1 1
1 1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 1
0 -1
0 -1
0 -1
...

result:

ok both questions correct

Test #40:

score: 2
Accepted
time: 2ms
memory: 3708kb

input:

1
100
0 27
0 25
0 6
1 3
0 1
0 15
0 3
1 5
0 12
1 7
1 4
0 38
1 6
0 4
1 1
0 8
1 10
0 1
0 3
0 4
1 8
1 9
0 18
0 11
0 20
1 14
1 16
0 16
1 17
1 11
1 12
1 15
0 4
0 11
1 18
0 5
1 20
0 5
0 5
0 4
0 1
1 24
0 19
0 6
0 19
0 7
0 3
0 8
0 2
0 6
1 32
0 8
0 1
0 9
0 7
0 7
1 34
1 37
0 11
1 27
1 31
1 26
1 22
1 23
0 47
1 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 27
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 4
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 ...

result:

ok both questions correct

Test #41:

score: 2
Accepted
time: 2ms
memory: 3692kb

input:

1
100
0 1
0 4
0 5
1 1
0 4
1 4
0 4
1 5
0 15
1 6
0 21
1 7
0 4
0 31
0 8
0 35
0 33
0 8
1 9
0 2
0 4
1 10
1 2
0 2
0 23
0 3
0 12
0 12
1 18
0 30
0 23
1 21
1 17
1 22
1 16
1 19
0 1
0 11
1 15
0 2
0 13
1 26
1 25
0 53
1 3
0 17
1 28
1 8
1 13
0 45
1 29
1 12
0 11
0 2
1 30
1 31
0 8
0 14
0 18
0 1
0 26
1 32
1 34
0 16
...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 1
0 -1
0 -1
0 -1
1 4
0 -1
1 4
0 -1
0 -1
0 -1
0 -1
0 -1
1 4
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
...

result:

ok both questions correct

Test #42:

score: 2
Accepted
time: 0ms
memory: 3752kb

input:

1
100
0 498
0 492
0 498
1 1
0 494
0 484
1 3
1 2
0 500
1 6
0 492
1 7
0 480
0 493
1 8
0 483
1 10
0 499
1 4
0 489
1 12
0 498
0 488
1 13
0 481
1 14
1 11
1 9
0 492
1 16
0 487
0 497
0 486
0 500
1 20
1 19
1 18
0 491
1 21
0 494
1 22
0 499
1 23
1 15
0 495
0 488
1 24
1 5
0 495
1 26
0 498
0 494
1 28
0 492
0 45...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 498
0 -1
1 498
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1...

result:

ok both questions correct

Test #43:

score: 2
Accepted
time: 2ms
memory: 3808kb

input:

1
100
0 496
0 470
0 498
0 481
0 489
0 489
1 3
1 2
0 493
0 477
0 493
0 498
0 494
1 11
1 7
1 10
1 1
0 488
1 8
1 6
0 500
1 9
0 498
1 14
1 13
0 497
0 490
0 500
0 478
1 18
0 496
0 492
0 497
0 490
1 19
1 20
1 17
0 491
0 498
1 24
1 5
1 4
0 497
1 23
0 496
0 483
0 496
1 26
0 479
1 27
0 498
0 493
1 30
0 488
1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 496
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
...

result:

ok both questions correct

Test #44:

score: 2
Accepted
time: 2ms
memory: 3704kb

input:

1
100
0 498
0 499
0 500
0 487
0 500
1 1
0 499
0 499
1 7
1 2
1 4
0 496
1 8
1 6
0 500
1 9
0 495
1 5
0 480
1 10
0 497
1 11
0 494
1 13
0 499
1 14
0 499
1 15
0 500
1 16
0 500
0 497
0 499
1 18
0 500
0 499
0 499
0 496
1 20
0 499
0 496
0 500
1 19
1 21
1 17
0 499
1 27
1 26
0 500
0 498
1 28
1 25
0 495
0 498
1...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 498
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 500
0 -1
1 500
1 500
1 500
1 500
1 500
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 500
0 -1
1 500
0 -1
0 -1
0 -1
1 500
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0...

result:

ok both questions correct

Test #45:

score: 2
Accepted
time: 1ms
memory: 3688kb

input:

1
100
0 8
0 8
0 5
1 2
0 2
0 7
1 3
1 5
0 9
1 1
0 7
1 4
0 8
1 8
0 7
1 9
0 3
0 3
1 10
0 7
1 12
1 11
0 8
0 4
1 14
0 1
0 9
0 5
1 16
1 13
1 15
0 9
1 17
1 6
0 7
0 1
0 6
1 21
0 8
1 19
1 20
1 22
0 4
1 23
0 9
0 7
0 1
1 26
1 25
1 24
0 3
0 3
0 8
1 29
0 7
1 28
1 27
0 2
0 5
1 32
1 31
0 3
1 33
1 30
0 3
0 8
0 8
1 3...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 8
1 8
1 8
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 9
0 -1
1 7
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 9
0 -1
0 -1
0 -...

result:

ok both questions correct

Test #46:

score: 2
Accepted
time: 0ms
memory: 3788kb

input:

1
100
0 496
0 493
0 500
0 499
1 2
0 499
0 500
1 6
1 3
1 1
0 499
1 4
0 485
1 8
0 500
1 9
0 499
1 7
0 500
1 11
0 493
0 500
1 12
1 13
0 497
1 14
0 497
0 500
0 495
1 16
0 498
1 15
1 17
1 18
0 495
1 19
0 497
1 20
0 500
0 500
0 498
0 492
0 500
0 499
0 498
1 24
1 27
0 491
1 28
1 26
0 499
1 29
0 500
1 30
0 ...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 496
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 499
1 499
1 499
1 499
1 499
1 499
1 499
1 499
1 499
1 499
1 499
1 499
1 499
0 -1
1 499
1 499
1 499
1 499
1 499
0 -1
0 -1
0 -1
0 -1
0 -1
1 499
1 499
1 499
1 499
1 499
1 499
1 499
0 -1
0 -1
...

result:

ok both questions correct

Test #47:

score: 0
Wrong Answer
time: 2ms
memory: 3664kb

input:

1
100
0 490
0 500
0 500
0 499
1 2
0 495
1 1
1 4
0 498
1 3
0 500
1 7
0 499
1 6
0 498
1 8
0 500
1 10
0 499
0 500
0 499
0 499
1 13
1 11
0 498
1 12
1 5
1 15
0 499
1 16
0 500
1 17
0 500
1 18
0 500
0 492
1 20
0 499
0 497
0 498
0 499
1 23
0 500
1 22
1 19
1 25
0 498
1 21
1 26
0 497
0 500
0 499
1 29
1 27
1 2...

output:

QOJ-SECURITYLIB-V23368-nhCapeXC2shGseuHTgYE-bt0m87qTfR8OPcSSLBkv
0 5
1 490
0 -1
1 500
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 498
0 -1
1 499
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
0 -1
1 499
1...

result:

wrong answer both questions wrong

Subtask #2:

score: 0
Runtime Error

Test #72:

score: 0
Runtime Error

input:

2
5000
0 2
0 1
0 3
1 3
0 4
1 4
0 3
1 5
0 1
0 2
1 7
1 1
0 2
0 3
0 3
1 9
1 8
1 10
0 1
1 11
0 2
0 4
1 12
0 4
0 4
0 3
1 14
1 15
0 1
1 13
0 3
0 3
1 2
0 4
0 3
1 21
0 1
1 22
1 20
1 6
1 16
1 19
0 3
1 23
0 4
0 1
0 1
1 25
1 18
1 17
0 4
0 4
0 1
0 4
0 2
1 31
1 28
1 27
0 4
1 32
1 29
1 26
0 4
1 33
0 2
0 3
1 35
1 ...

output:


result:


Subtask #3:

score: 0
Runtime Error

Test #143:

score: 0
Runtime Error

input:

3
50000
0 2
0 1
0 1
1 1
0 4
1 2
0 1
1 4
0 3
1 6
0 4
1 7
0 1
0 4
1 3
1 8
0 3
0 1
0 2
0 3
1 10
1 13
0 3
0 2
0 1
0 2
1 14
1 17
0 4
0 1
1 18
1 15
1 16
0 4
0 1
1 20
1 21
1 19
1 11
1 5
0 1
0 4
1 23
1 9
0 1
1 24
0 3
0 1
1 25
1 26
0 3
0 3
1 27
1 28
0 1
1 29
0 4
0 4
0 1
1 31
1 30
0 1
1 33
1 32
0 4
0 4
1 34
1...

output:


result:


Subtask #4:

score: 0
Runtime Error

Test #214:

score: 0
Runtime Error

input:

4
100000
0 3
0 3
0 3
0 4
0 2
1 4
0 2
0 2
0 3
0 2
0 1
0 2
0 3
0 1
1 7
1 5
1 12
0 2
0 2
1 1
1 10
0 2
1 14
0 3
1 17
0 2
1 8
0 1
0 1
0 4
1 20
1 11
1 6
0 1
1 9
1 21
1 19
1 18
1 22
1 3
1 15
1 16
0 1
0 2
0 2
1 23
0 2
0 2
1 26
0 4
0 4
1 29
1 25
0 4
0 1
0 3
0 2
1 31
1 32
1 24
0 4
1 34
1 27
0 4
0 2
0 1
1 35
0...

output:


result: