QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#91044 | #4218. Hidden Graph | Qiuly | TL | 119ms | 4004kb | C++14 | 2.2kb | 2023-03-26 20:42:05 | 2023-03-26 20:42:06 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 2ms
memory: 3576kb
input:
3 1 3 2 3 1 2
output:
? 3 1 2 3 ? 2 2 3 ? 2 1 2 ! 3 1 3 1 2 2 3
result:
ok correct
Test #2:
score: 0
Accepted
time: 0ms
memory: 3588kb
input:
10 1 4 2 6 3 7 4 10 -1 -1 3 10 2 5 1 2 -1 -1 3 8 4 5 4 8 3 9 -1 -1 1 3 -1 -1 -1 -1
output:
? 10 1 2 3 4 5 6 7 8 9 10 ? 9 2 3 4 5 6 7 8 9 10 ? 8 1 2 3 5 7 8 9 10 ? 7 4 5 6 7 8 9 10 ? 7 1 5 6 7 8 9 10 ? 7 1 2 3 5 8 9 10 ? 6 2 4 5 7 8 9 ? 6 1 2 7 8 9 10 ? 5 2 7 8 9 10 ? 6 3 4 5 6 8 9 ? 5 3 4 5 6 9 ? 5 4 6 7 8 9 ? 4 3 4 6 9 ? 3 2 3 4 ? 4 1 3 5 6 ? 4 4 6 7 9 ? 3 3 5 6 ! 12 1 4...
result:
ok correct
Test #3:
score: 0
Accepted
time: 2ms
memory: 3576kb
input:
5 5 2 2 1 3 1 4 2 -1 -1 4 1 3 2 5 1
output:
? 5 1 2 3 4 5 ? 4 1 2 3 4 ? 4 1 3 4 5 ? 3 2 3 4 ? 3 3 4 5 ? 3 1 4 5 ? 2 2 3 ? 2 1 5 ! 7 1 2 1 3 1 4 1 5 2 5 2 4 2 3
result:
ok correct
Test #4:
score: 0
Accepted
time: 2ms
memory: 3568kb
input:
3 1 3 -1 -1 2 1
output:
? 3 1 2 3 ? 2 2 3 ? 2 1 2 ! 2 1 3 1 2
result:
ok correct
Test #5:
score: 0
Accepted
time: 3ms
memory: 3620kb
input:
6 3 6 4 2 1 2 4 5 2 5 -1 -1 3 1 -1 -1 3 2 -1 -1 3 4 3 5
output:
? 6 1 2 3 4 5 6 ? 5 1 2 4 5 6 ? 4 1 2 3 5 ? 4 1 4 5 6 ? 3 2 5 6 ? 3 1 4 6 ? 3 1 3 4 ? 3 1 5 6 ? 2 2 3 ? 2 2 6 ? 2 3 4 ? 2 3 5 ! 9 1 2 1 3 2 4 2 5 2 3 3 6 3 4 3 5 4 5
result:
ok correct
Test #6:
score: 0
Accepted
time: 6ms
memory: 3612kb
input:
27 5 20 12 11 22 26 1 8 21 17 6 13 23 27 20 18 6 24 22 25 14 12 4 11 21 2 10 16 24 19 10 15 2 19 3 21 2 27 14 8 7 26 5 13 17 25 9 20 21 18 21 19 14 1 14 19 16 18 3 5 14 24 24 10 14 5 6 8 7 22 10 13 5 26 10 8 22 16 22 13 8 13 3 15 3 1 6 1 19 26 1 19 26 13 19 13 21 25 17 26 19 11 24 13 -1 -1 5 19 21 2...
output:
? 27 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 ? 26 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 21 22 23 24 25 26 27 ? 25 1 2 3 4 6 7 8 9 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 ? 24 1 2 3 4 6 7 8 9 10 12 13 14 15 16 17 18 19 20 21 23 24 25 26 27 ? 23...
result:
ok correct
Test #7:
score: 0
Accepted
time: 17ms
memory: 3736kb
input:
47 42 1 20 10 19 21 17 35 43 2 18 11 4 15 43 36 11 26 7 5 41 37 5 8 46 3 18 32 40 36 44 47 10 7 18 25 21 45 21 25 26 47 31 24 22 34 6 37 5 44 7 6 28 40 39 32 27 9 19 29 43 3 45 26 19 2 13 15 31 36 22 11 7 12 23 18 29 35 29 32 46 5 27 5 40 3 13 42 23 3 17 18 34 32 17 39 38 30 16 1 19 5 46 9 42 45 19 ...
output:
? 47 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 ? 46 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 43 44 45 46 47 ? 45 2 3 4 5 6 7 8 9 10 11 ...
result:
ok correct
Test #8:
score: 0
Accepted
time: 8ms
memory: 3632kb
input:
38 16 27 38 12 16 13 13 33 28 8 23 25 14 34 24 6 4 18 13 12 14 18 4 17 19 32 1 23 12 7 31 29 3 5 30 34 11 37 6 7 31 17 38 14 28 22 4 5 31 1 15 22 26 27 31 6 30 17 4 20 20 35 38 13 8 35 4 7 4 19 24 33 37 18 13 8 28 33 15 27 29 35 29 3 7 18 37 34 2 25 6 20 28 9 16 12 12 8 37 6 28 12 26 19 1 14 1 5 2 7...
output:
? 38 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 ? 37 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 28 29 30 31 32 33 34 35 36 37 38 ? 36 1 2 3 4 5 6 7 8 9 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 28 29 30 3...
result:
ok correct
Test #9:
score: 0
Accepted
time: 6ms
memory: 3668kb
input:
25 4 22 16 8 7 17 14 25 12 25 19 11 10 3 8 23 5 21 18 8 18 4 16 12 20 6 7 13 13 8 20 9 2 22 14 22 9 4 16 13 16 3 5 2 10 15 25 3 14 3 6 24 5 4 14 13 7 19 20 23 25 24 16 21 4 17 12 4 18 22 13 21 18 13 8 21 10 17 22 3 7 20 21 11 13 19 5 7 9 8 13 22 16 9 7 14 20 3 2 11 9 11 2 25 10 11 6 22 4 8 6 12 24 1...
output:
? 25 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 ? 24 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 23 24 25 ? 23 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 17 18 19 20 21 23 24 25 ? 22 1 2 3 5 6 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 ? 21 1 2 3 4 5 6 7 8 9 10 1...
result:
ok correct
Test #10:
score: 0
Accepted
time: 2ms
memory: 3504kb
input:
6 2 3 2 5 5 6 -1 -1 -1 -1 -1 -1
output:
? 6 1 2 3 4 5 6 ? 5 1 2 4 5 6 ? 5 1 3 4 5 6 ? 4 1 2 4 6 ? 4 1 3 4 5 ? 2 3 6 ! 3 2 3 2 5 5 6
result:
ok correct
Test #11:
score: 0
Accepted
time: 1ms
memory: 3680kb
input:
3 2 1 2 3 3 1
output:
? 3 1 2 3 ? 2 2 3 ? 2 1 3 ! 3 1 2 1 3 2 3
result:
ok correct
Test #12:
score: 0
Accepted
time: 1ms
memory: 3688kb
input:
3 2 1 -1 -1 3 1
output:
? 3 1 2 3 ? 2 2 3 ? 2 1 3 ! 2 1 2 1 3
result:
ok correct
Test #13:
score: 0
Accepted
time: 3ms
memory: 3644kb
input:
5 2 1 2 3 2 5 3 1 -1 -1 -1 -1 5 1 -1 -1
output:
? 5 1 2 3 4 5 ? 4 2 3 4 5 ? 3 2 4 5 ? 4 1 3 4 5 ? 3 3 4 5 ? 2 2 4 ? 3 1 4 5 ? 2 1 4 ! 5 1 2 1 3 1 5 2 3 2 5
result:
ok correct
Test #14:
score: 0
Accepted
time: 2ms
memory: 3572kb
input:
3 2 1 -1 -1 -1 -1
output:
? 3 1 2 3 ? 2 2 3 ? 2 1 3 ! 1 1 2
result:
ok correct
Test #15:
score: 0
Accepted
time: 2ms
memory: 3716kb
input:
5 3 5 4 3 2 5 -1 -1 -1 -1 -1 -1
output:
? 5 1 2 3 4 5 ? 4 1 2 3 4 ? 4 1 2 4 5 ? 3 1 2 3 ? 3 1 2 4 ? 3 1 4 5 ! 3 2 5 3 5 3 4
result:
ok correct
Test #16:
score: 0
Accepted
time: 32ms
memory: 3856kb
input:
93 85 13 84 87 9 90 43 32 33 87 80 24 10 93 88 73 7 11 62 33 77 57 56 77 35 80 68 26 10 41 70 21 83 36 82 15 91 89 32 63 8 85 63 26 44 19 3 71 81 4 36 2 92 13 8 16 49 45 40 87 37 66 51 23 19 18 56 44 62 58 59 14 65 74 32 86 65 51 40 35 49 40 71 69 75 65 62 92 37 86 85 76 81 61 5 44 73 30 53 15 2 39 ...
output:
? 93 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 ? 92 1 2 3 4 5 6 7 8 9 1...
result:
ok correct
Test #17:
score: 0
Accepted
time: 69ms
memory: 3888kb
input:
111 48 35 88 68 53 108 10 98 44 7 110 43 6 37 93 45 24 39 42 54 20 105 85 44 37 99 86 60 79 25 47 5 92 51 67 13 85 94 70 60 49 100 40 30 42 27 27 101 97 56 93 33 57 100 57 71 41 62 83 68 27 45 65 4 31 92 41 52 18 5 17 111 7 12 107 71 97 28 3 76 75 91 1 99 78 109 96 71 107 56 59 21 96 27 21 15 83 57 ...
output:
? 111 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 10...
result:
ok correct
Test #18:
score: 0
Accepted
time: 119ms
memory: 4004kb
input:
132 106 11 53 86 22 20 29 62 28 41 67 109 106 110 4 48 121 70 124 109 64 46 54 4 63 50 89 113 121 53 60 48 6 106 39 12 2 59 82 100 6 109 110 92 93 8 7 113 52 129 83 15 79 116 49 14 19 39 30 23 103 76 24 61 131 9 1 105 29 14 80 111 95 100 38 7 124 72 103 81 16 35 21 48 72 64 97 115 62 108 67 31 43 10...
output:
? 132 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 10...
result:
ok correct
Test #19:
score: 0
Accepted
time: 66ms
memory: 3952kb
input:
94 40 68 20 12 72 34 73 57 87 55 93 12 51 36 17 70 16 45 47 85 65 33 43 22 57 19 27 78 25 66 23 13 88 89 55 66 53 86 5 41 80 7 92 59 61 75 65 21 14 65 37 40 91 28 31 59 79 7 60 56 71 37 81 70 35 63 31 23 70 44 27 76 6 45 84 28 94 9 38 9 67 4 82 26 33 93 81 50 43 12 47 53 29 80 48 85 52 72 78 49 8 93...
output:
? 94 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 ? 93 1 2 3 4 5 6 7 8 ...
result:
ok correct
Test #20:
score: 0
Accepted
time: 31ms
memory: 3896kb
input:
73 49 43 23 20 55 16 60 72 30 34 53 26 51 38 4 34 3 10 69 8 1 9 42 27 63 7 71 11 9 35 59 64 39 43 29 35 49 53 19 20 13 22 28 2 25 16 17 57 25 24 48 6 4 11 13 39 1 3 9 65 26 7 6 65 45 31 46 73 50 18 51 42 49 23 28 63 48 64 71 26 9 45 20 14 57 70 13 19 12 72 29 19 59 68 52 11 31 8 72 44 30 70 52 10 44...
output:
? 73 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 ? 72 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 3...
result:
ok correct
Test #21:
score: 0
Accepted
time: 34ms
memory: 3764kb
input:
77 68 77 5 69 58 34 16 61 16 63 7 36 13 28 40 72 16 42 51 11 24 41 70 77 16 45 63 35 4 30 66 18 52 23 32 6 58 15 69 17 57 7 20 4 14 21 75 34 3 56 50 10 63 56 68 62 60 24 12 45 44 43 70 47 62 65 59 65 50 47 50 25 2 61 60 1 11 54 27 17 2 57 2 20 21 72 50 19 66 67 20 28 26 77 74 61 14 35 40 17 52 7 3 7...
output:
? 77 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 ? 76 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 2...
result:
ok correct
Test #22:
score: 0
Accepted
time: 60ms
memory: 3804kb
input:
81 6 53 65 31 72 75 1 47 18 41 10 48 79 68 39 62 2 28 75 21 61 57 10 13 4 71 62 70 8 51 66 24 46 78 8 21 69 63 32 16 47 75 20 72 25 34 19 63 30 19 18 6 50 68 37 45 37 11 60 52 41 23 8 12 65 37 49 74 65 43 44 53 50 36 39 70 42 62 75 12 30 57 30 81 58 68 18 56 39 21 58 71 27 5 50 3 48 55 49 63 47 35 3...
output:
? 81 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 ? 80 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 2...
result:
ok correct
Test #23:
score: 0
Accepted
time: 63ms
memory: 3808kb
input:
93 43 63 75 46 42 15 86 56 54 49 2 22 75 65 61 68 38 82 93 48 43 70 16 30 37 81 74 20 29 39 40 84 57 44 45 32 7 77 78 88 20 34 14 58 27 64 3 23 85 46 25 42 4 42 89 34 93 37 36 32 27 23 74 53 61 82 74 44 33 22 86 77 53 82 9 66 46 87 79 18 71 6 20 27 57 38 17 28 54 17 24 92 69 12 90 10 53 77 53 20 17 ...
output:
? 93 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 ? 92 1 2 3 4 5 6 7 8 9 1...
result:
ok correct
Test #24:
score: 0
Accepted
time: 8ms
memory: 3644kb
input:
37 4 26 22 20 12 13 9 8 32 11 6 18 3 1 32 31 3 27 10 21 24 13 7 34 36 14 19 23 14 29 31 8 24 34 12 24 33 27 35 5 2 9 30 29 30 11 15 10 6 14 11 17 1 17 30 20 2 18 9 11 2 25 4 37 9 29 30 16 33 26 4 11 6 27 29 10 35 37 15 23 25 23 5 16 35 1 36 19 28 18 32 19 33 25 25 20 17 34 19 21 11 23 21 34 15 8 30 ...
output:
? 37 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 ? 36 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 27 28 29 30 31 32 33 34 35 36 37 ? 35 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 23 24 25 27 28 29 30 31 32 3...
result:
ok correct
Test #25:
score: 0
Accepted
time: 4ms
memory: 3992kb
input:
144 32 45 144 11 112 23 134 99 86 3 66 54 129 75 17 62 5 22 60 76 102 28 53 71 102 90 140 113 144 135 92 116 56 46 29 141 135 126 81 43 91 60 106 67 14 144 100 138 28 139 127 96 102 111 72 36 35 33 19 104 74 72 62 115 29 64 3 50 86 19 123 132 79 17 86 78 57 66 14 18 82 137 79 121 60 56 108 42 62 47 ...
output:
? 144 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 10...
result:
ok correct
Test #26:
score: -100
Time Limit Exceeded
input:
561 474 295 549 379 161 321 259 479 286 386 12 289 77 146 412 347 359 399 332 172 485 231 518 140 550 271 102 324 530 61 78 261 306 119 513 21 153 274 296 522 224 330 7 427 441 287 173 207 343 255 165 364 462 279 530 427 96 237 179 45 494 448 272 394 116 6 344 130 501 5 79 365 55 258 361 167 347 143...
output:
? 561 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 10...