QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#536521#3059. Buffalo BarricadesqiuzxTL 103ms140360kbC++203.0kb2024-08-29 14:15:032024-08-29 14:15:03

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 16ms
memory: 128060kb

input:

7
1 1
4 2
6 2
5 3
2 5
4 7
7 5
4
4 4
8 2
9 6
6 5

output:

2
1
3
2

result:

ok 4 lines

Test #2:

score: 0
Accepted
time: 12ms
memory: 128804kb

input:

10
64 37
51 67
97 74
45 85
1 23
87 85
67 58
67 25
36 19
34 11
10
88 5
3 27
95 88
63 56
28 61
93 89
82 51
96 24
49 26
22 52

output:

0
1
8
2
0
0
2
0
2
0

result:

ok 10 lines

Test #3:

score: 0
Accepted
time: 16ms
memory: 129728kb

input:

900
5029 361
3803 9216
237 5194
9957 937
2738 7305
6543 6871
7355 4400
5526 7160
4945 3009
1765 3846
7840 3082
9780 5016
6026 4387
8260 2089
7974 90
7316 9354
451 1119
4921 7039
6312 1229
7975 5401
8533 4518
8623 5887
5269 4148
9399 6566
7156 1163
6763 1347
597 6542
2714 6622
7280 973
8710 1605
7415...

output:

8
185
345
54
45
2
2
5
24
14
0
33
7
5
121
12
4
4
7
33
25
1
8
13
13
6
70
2
68
2
8
23
35
10
0
1
2
2
1
0
0
3
2
8
0
7
25
2
1
1
10
14
6
23
1
4
13
0
1
0
1
2
24
41
2
7
12
6
32
11
2
6
0
34
0
2
1
2
0
5
0
8
1
0
5
0
0
0
0
15
1
6
9
2
3
0
11
1
3
15
3
0
0
1
0
37
44
0
0
1
0
0
0
11
3
1
8
2
19
0
2
0
13
0
6
5
2
0
7
7
...

result:

ok 1000 lines

Test #4:

score: 0
Accepted
time: 103ms
memory: 140360kb

input:

30000
154617 358190
969920 171311
790814 429690
89355 649753
442368 271204
60616 431884
510477 256960
159511 155485
520908 213115
484807 932304
470644 434803
620533 717052
13985 236182
449546 808653
452658 725252
379440 123627
83441 349359
294937 390606
295400 384292
40359 737767
171847 100974
16965...

output:

1430
13897
1541
369
3472
10516
73
5205
2812
565
1432
666
503
4002
96
424
848
694
88
224
929
48
118
43
576
116
43
285
137
154
158
1627
178
340
955
1220
2
121
5
31
469
347
50
124
599
26
346
3
111
170
386
7
167
16
1209
55
43
0
80
57
32
57
11
11
0
363
537
184
779
198
40
136
218
10
80
0
78
0
245
451
228
...

result:

ok 10000 lines

Test #5:

score: -100
Time Limit Exceeded

input:

290000
717671719 278332807
993676424 306880299
689750274 48112672
110955934 517289545
975767840 971258772
638293491 769857435
658579174 843203114
292289080 20706019
261920626 565699908
281395889 136167636
376998346 567544956
746820500 500595235
420288210 944489322
297519453 26062002
186972379 706335...

output:


result: