QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#403286#6240. 游戏dXqwq100 ✓215ms78852kbC++231.6kb2024-05-02 00:32:042024-05-02 00:32:05

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 10
Accepted
time: 0ms
memory: 16864kb

input:

1000 699 1000
2 3
3 4
5 18
7 8
8 9
10 151
12 13
16 28
17 18
18 28
24 27
25 26
26 28
27 29
28 29
30 31
31 33
33 50
34 34
35 34
36 36
38 35
41 41
42 42
43 43
44 44
45 45
47 47
49 46
50 45
52 52
53 43
54 45
55 42
57 57
60 55
63 63
64 64
65 65
66 65
67 65
69 64
71 65
73 72
74 74
75 75
76 74
78 78
81 80
...

output:

YES
NO
YES
NO
NO
YES
NO
NO
YES
NO
NO
YES
NO
NO
NO
YES
NO
NO
YES
YES
YES
NO
NO
NO
NO
NO
NO
YES
YES
NO
YES
NO
YES
NO
NO
NO
YES
NO
NO
YES
YES
YES
NO
YES
NO
NO
NO
YES
NO
YES
NO
NO
YES
YES
NO
NO
YES
YES
NO
NO
YES
NO
NO
NO
NO
YES
YES
NO
NO
NO
YES
NO
NO
YES
NO
NO
YES
YES
YES
YES
YES
YES
YES
NO
NO
YES
NO
NO...

result:

ok 1000 token(s): yes count is 498, no count is 502

Test #2:

score: 10
Accepted
time: 0ms
memory: 16744kb

input:

1000 699 1000
1 3
3 8
4 7
5 9
7 8
9 11
11 210
13 838
14 15
15 16
17 434
18 194
19 668
20 22
22 182
23 24
24 109
26 461
27 28
28 351
30 32
32 35
33 34
34 35
35 38
37 38
38 173
40 84
41 42
42 56
44 45
45 48
47 48
48 49
49 54
51 52
52 53
53 55
55 56
56 57
57 58
58 61
61 63
62 63
63 88
64 72
66 83
67 88...

output:

NO
YES
YES
YES
YES
YES
YES
NO
YES
YES
YES
NO
YES
YES
NO
NO
NO
YES
YES
YES
NO
YES
YES
NO
YES
NO
NO
NO
YES
NO
YES
YES
NO
NO
YES
NO
NO
YES
YES
YES
YES
YES
YES
YES
YES
YES
YES
YES
YES
YES
YES
NO
NO
YES
NO
NO
YES
YES
NO
YES
YES
YES
YES
YES
NO
NO
NO
NO
NO
NO
YES
YES
NO
YES
YES
NO
YES
NO
NO
YES
YES
YES
NO
...

result:

ok 1000 token(s): yes count is 504, no count is 496

Test #3:

score: 10
Accepted
time: 17ms
memory: 28400kb

input:

100000 89999 100000
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
10 9
11 11
12 12
13 13
14 14
15 15
16 16
17 17
18 18
20 20
21 21
22 22
23 23
24 24
25 25
26 26
27 27
28 28
30 29
31 31
32 32
33 33
35 35
36 36
37 37
38 38
39 39
40 40
41 41
42 42
44 44
45 45
46 46
48 47
49 49
50 50
51 51
52 52
53 53
54 54
55 55
56 ...

output:

YES
YES
YES
NO
NO
YES
YES
YES
YES
NO
YES
NO
YES
YES
YES
NO
NO
YES
NO
NO
NO
YES
NO
YES
NO
NO
NO
YES
NO
NO
NO
YES
YES
YES
YES
YES
NO
YES
NO
YES
NO
YES
NO
YES
NO
NO
NO
YES
YES
NO
YES
NO
NO
NO
YES
NO
NO
NO
NO
YES
YES
NO
YES
NO
NO
YES
NO
NO
YES
YES
NO
NO
YES
YES
YES
YES
YES
NO
NO
YES
NO
YES
NO
NO
YES
YES...

result:

ok 100000 token(s): yes count is 54336, no count is 45664

Test #4:

score: 10
Accepted
time: 16ms
memory: 23212kb

input:

100000 89999 100000
1 1
2 2
4 4
5 5
6 6
7 7
8 8
9 9
10 10
12 12
13 13
14 14
15 15
16 16
17 17
18 18
19 19
22 22
23 23
24 24
25 25
26 26
27 27
28 28
29 29
30 30
31 31
32 32
34 34
35 35
37 37
38 38
39 39
41 40
42 42
43 43
44 44
45 45
46 46
47 47
48 48
49 49
50 50
51 51
52 52
53 53
54 54
55 55
56 56
57...

output:

NO
YES
YES
NO
YES
NO
YES
NO
YES
YES
YES
YES
NO
YES
NO
YES
NO
YES
NO
YES
YES
YES
NO
YES
NO
NO
YES
YES
YES
NO
YES
NO
YES
NO
NO
NO
NO
YES
NO
NO
YES
YES
NO
NO
YES
NO
YES
YES
NO
NO
NO
NO
NO
NO
NO
YES
YES
NO
YES
NO
YES
NO
YES
YES
NO
NO
YES
YES
YES
YES
NO
NO
YES
YES
YES
YES
NO
NO
NO
NO
NO
YES
YES
NO
NO
NO
...

result:

ok 100000 token(s): yes count is 55025, no count is 44975

Test #5:

score: 10
Accepted
time: 18ms
memory: 27848kb

input:

100000 94999 100000
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 10
11 11
12 12
13 13
14 14
15 15
16 16
17 17
18 18
19 19
20 20
21 21
22 22
23 23
24 24
25 25
26 26
27 27
28 28
29 29
30 30
31 31
32 32
33 33
34 34
35 35
36 36
37 37
38 38
39 39
40 40
41 41
42 42
43 43
44 44
45 45
46 46
47 47
48 48
49 49
50 5...

output:

NO
NO
NO
NO
NO
YES
NO
YES
YES
NO
YES
NO
YES
YES
YES
NO
YES
NO
YES
YES
YES
YES
NO
NO
YES
YES
NO
NO
NO
NO
YES
NO
YES
YES
YES
NO
YES
YES
YES
YES
YES
NO
YES
NO
YES
YES
YES
NO
NO
NO
NO
NO
NO
NO
YES
NO
NO
NO
NO
YES
NO
NO
YES
NO
NO
NO
NO
YES
NO
NO
YES
NO
NO
YES
YES
YES
YES
NO
NO
YES
NO
NO
NO
NO
NO
NO
NO
YE...

result:

ok 100000 token(s): yes count is 47899, no count is 52101

Test #6:

score: 10
Accepted
time: 21ms
memory: 25556kb

input:

100000 99998 100000
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 10
11 11
12 12
13 13
14 14
15 15
16 16
17 17
18 18
19 19
20 20
21 21
22 22
23 23
24 24
25 25
26 26
27 27
28 28
29 29
30 30
31 31
32 32
33 33
34 34
35 35
36 36
37 37
38 38
39 39
40 40
41 41
42 42
43 43
44 44
45 45
46 46
47 47
48 48
49 49
50 5...

output:

NO
NO
YES
NO
NO
NO
NO
YES
NO
NO
YES
NO
NO
NO
YES
YES
YES
YES
NO
NO
NO
NO
YES
NO
NO
NO
NO
YES
YES
NO
NO
NO
NO
NO
NO
NO
NO
YES
NO
YES
YES
NO
NO
NO
NO
NO
YES
NO
NO
NO
YES
NO
NO
YES
NO
YES
YES
YES
NO
NO
NO
NO
NO
YES
NO
NO
NO
YES
NO
YES
NO
NO
NO
YES
YES
YES
YES
YES
NO
YES
YES
YES
YES
NO
NO
NO
NO
YES
NO
Y...

result:

ok 100000 token(s): yes count is 35864, no count is 64136

Test #7:

score: 10
Accepted
time: 203ms
memory: 77220kb

input:

1000000 899999 1000000
1 1
2 2
3 3
5 5
7 6
8 8
10 9
11 11
12 12
14 14
15 15
16 16
17 17
18 18
19 19
20 20
21 21
22 22
23 23
24 24
25 25
27 26
28 28
29 29
30 30
31 31
32 32
33 33
34 34
35 35
36 36
37 37
38 38
40 40
42 41
43 43
44 44
45 45
46 46
47 47
48 48
49 49
50 50
51 51
52 52
53 53
54 54
55 55
56...

output:

YES
YES
YES
NO
YES
NO
YES
NO
NO
NO
YES
YES
YES
NO
NO
YES
NO
NO
YES
NO
YES
YES
YES
NO
YES
YES
YES
NO
YES
NO
NO
YES
NO
YES
YES
NO
NO
NO
NO
NO
NO
YES
NO
YES
NO
YES
YES
YES
YES
NO
YES
YES
NO
NO
NO
YES
NO
NO
NO
YES
NO
YES
YES
YES
NO
NO
YES
YES
YES
NO
YES
NO
YES
YES
NO
YES
YES
NO
NO
NO
YES
NO
NO
NO
YES
NO...

result:

ok 1000000 token(s): yes count is 544451, no count is 455549

Test #8:

score: 10
Accepted
time: 215ms
memory: 75804kb

input:

1000000 799999 1000000
1 1
3 2
4 4
5 5
6 6
7 7
9 9
11 10
13 12
15 14
16 16
18 17
20 20
21 21
23 22
24 24
25 25
26 26
27 27
29 29
30 30
31 31
32 32
33 33
34 34
36 36
37 37
38 38
39 39
40 40
41 41
42 42
43 43
44 44
45 45
46 46
47 47
49 49
50 50
51 51
52 52
54 53
55 55
56 56
57 57
58 58
59 59
61 61
62 ...

output:

NO
YES
NO
YES
YES
YES
YES
YES
YES
YES
NO
YES
YES
YES
YES
YES
YES
NO
YES
NO
YES
NO
YES
NO
NO
NO
NO
NO
YES
YES
YES
NO
YES
NO
YES
YES
YES
YES
YES
NO
NO
YES
NO
YES
YES
NO
YES
NO
YES
YES
YES
NO
YES
YES
YES
NO
NO
NO
NO
YES
NO
NO
YES
NO
YES
YES
YES
NO
NO
NO
NO
YES
YES
YES
YES
YES
NO
YES
YES
NO
YES
YES
YES
...

result:

ok 1000000 token(s): yes count is 550084, no count is 449916

Test #9:

score: 10
Accepted
time: 181ms
memory: 77444kb

input:

1000000 899999 1000000
1 1
2 2
3 3
6 5
7 7
8 8
9 9
10 10
11 11
12 12
13 13
14 14
15 15
16 16
17 17
18 18
20 20
21 21
22 22
23 23
24 24
26 25
27 27
28 28
29 29
32 31
33 33
34 34
35 35
36 36
37 37
38 38
39 39
40 40
41 41
42 42
43 43
44 44
45 45
46 46
47 47
48 48
50 49
51 51
52 52
54 53
55 55
56 56
57 ...

output:

YES
NO
NO
NO
YES
YES
YES
NO
NO
NO
YES
YES
YES
NO
YES
YES
NO
NO
NO
NO
NO
NO
YES
YES
YES
YES
NO
YES
YES
YES
YES
YES
NO
YES
NO
YES
NO
NO
YES
YES
YES
NO
NO
YES
YES
NO
YES
YES
YES
NO
YES
NO
NO
YES
NO
NO
YES
YES
YES
YES
NO
YES
YES
YES
YES
YES
NO
YES
YES
YES
NO
YES
NO
YES
NO
YES
NO
NO
NO
NO
YES
YES
YES
YES...

result:

ok 1000000 token(s): yes count is 503879, no count is 496121

Test #10:

score: 10
Accepted
time: 194ms
memory: 78852kb

input:

1000000 999999 1000000
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 10
11 11
12 12
13 13
14 14
15 15
16 16
17 17
18 18
19 19
20 20
21 21
22 22
23 23
24 24
25 25
26 26
27 27
28 28
29 29
30 30
31 31
32 32
33 33
34 34
35 35
36 36
37 37
38 38
39 39
40 40
41 41
42 42
43 43
44 44
45 45
46 46
47 47
48 48
49 49
5...

output:

YES
NO
NO
YES
NO
NO
NO
NO
YES
NO
NO
YES
NO
YES
YES
NO
YES
YES
YES
YES
YES
NO
NO
NO
YES
NO
NO
NO
YES
NO
NO
NO
NO
YES
YES
YES
NO
YES
YES
YES
YES
NO
NO
YES
YES
NO
NO
NO
YES
YES
NO
NO
YES
NO
NO
YES
YES
NO
NO
NO
YES
YES
YES
NO
YES
NO
NO
NO
NO
NO
NO
YES
YES
YES
YES
YES
YES
NO
YES
NO
YES
YES
NO
NO
NO
NO
NO...

result:

ok 1000000 token(s): yes count is 506286, no count is 493714