QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#505514#5909. Treasurexiaowuc180 ✓5ms3828kbC++173.9kb2024-08-05 05:51:312024-08-05 05:51:33

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 20
Accepted

Test #1:

score: 20
Accepted
time: 1ms
memory: 3828kb

input:

25
1 20
9
1 1 16
6 1 8
7 3 16 12 13
16 4 20 6 4 19
17 3 14 11 11
18 3 13 12 6
13 2 3 7
11 2 20 3
14 1 4
2 2 4 18
9 2 14 5
19 3 2 13 17
8 1 17
3 2 5 15
5 1 10
20 2 10 2
12 1 20
4 2 19 1
15 1 14
10 2 1 19
5 20
2 1 4 2 1
3 0
1 3 2 2 4
2 4 3 3 1 1
3 1 3
4 1 2
3 1 4
1 2 3 4
3 1 1
1 2 2 2
4 2 4 1
4 1 2
4 ...

output:

Case #1: 11 9 15 18 1 4 2 12 5 7 3 8 10 6 13 14 16 17 19 20
Case #2: IMPOSSIBLE
Case #3: IMPOSSIBLE
Case #4: 1 2 3 4 6 7 9 5 11 12 13 15 16 17 8 18 19 10 20 14
Case #5: 1 2 3 4 5
Case #6: 1 2 3 4 5 6 8 9 11 7 10 12 13 14 15
Case #7: IMPOSSIBLE
Case #8: 1
Case #9: 3 2 5 7 4 1 6 9 10 11 8 12 13 14 15 ...

result:

ok 25 lines

Subtask #2:

score: 60
Accepted

Test #2:

score: 60
Accepted
time: 5ms
memory: 3792kb

input:

25
1 200
200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 1 200
200 0
200 1 200
200 1 200
200 1 200
200 1 200
2...

output:

Case #1: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 25 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100...

result:

ok 25 lines

Extra Test:

score: 0
Extra Test Passed