QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#659123 | #2789. Sorting | Pioneer | 100 ✓ | 326ms | 32224kb | C++20 | 1.6kb | 2024-10-19 18:47:05 | 2024-10-19 18:47:05 |
Judging History
answer
#include "sorting.h"
#include <bits/stdc++.h>
using namespace std;
const int MAX=200000;
int n,m;
int findSwapPairs(int N, int S[], int M, int X[], int Y[], int P[], int Q[]) {
n=N,m=M;
vector<int> v(n),need(n);
vector<pair<int,int>> swaps;
for(int i=0;i<n;i++)v[i]=S[i],need[i]=i;
vector<int> tov=need;
for(int j=0;j<m;j++){
swap(tov[X[j]],tov[Y[j]]);
}
vector<int> tov1(n);
for(int i=0;i<n;i++)tov1[tov[i]]=i;
swap(tov,tov1);
for(int i=0;i<n;i++){
tov1[tov[i]]=i;
}
set<int> st;
for(int i=0;i<n;i++){
if(tov[i]!=v[i])st.insert(i);
}
for(int i=0;i<m;i++){
bool kx=0,ky=0;
if(st.count(X[i])){
kx=1;
st.erase(X[i]);
}
if(st.count(Y[i])){
ky=1;
st.erase(Y[i]);
}
if(kx){
st.insert(Y[i]);
}
if(ky){
st.insert(X[i]);
}
swap(v[X[i]],v[Y[i]]);
assert(tov1[tov[X[i]]]==X[i]);
assert(tov1[tov[Y[i]]]==Y[i]);
swap(tov1[tov[X[i]]],tov1[tov[Y[i]]]);
swap(tov[X[i]],tov[Y[i]]);
while(!st.empty()&&tov[*st.begin()]==v[*st.begin()])st.erase(st.begin());
if(!st.empty()){
int k=*st.begin();
st.erase(st.begin());
int j=tov1[v[k]];
swaps.push_back({k,j});
// assert(tov[j]==v[k]);
// 0 5 5 1
// 0 2 5 3
// 0 3 0 2
// 0 4 0 4
// OK
swap(v[k],v[j]);
// cout<<i<<" "<<k<<" "<<j<<" "<<tov[k]<<" "<<v[k]<<" "<<tov[j]<<" "<<v[j]<<"\n";
if(tov[j]!=v[j])st.insert(j);
if(tov[k]!=v[k])st.insert(k);
// cout<<st.size()<<"\n";
}
else swaps.push_back({0,0});
}
assert(v==need);
for(int i=0;i<m;i++){
P[i]=swaps[i].first;
Q[i]=swaps[i].second;
}
return M;
}
详细
Subtask #1:
score: 8
Accepted
Test #1:
score: 8
Accepted
time: 0ms
memory: 3728kb
input:
1 0 1 0 0
output:
1 0 0
result:
ok correct
Test #2:
score: 8
Accepted
time: 0ms
memory: 3660kb
input:
2 0 1 4 0 0 0 0 0 0 0 0
output:
4 0 0 0 0 0 0 0 0
result:
ok correct
Test #3:
score: 8
Accepted
time: 0ms
memory: 3756kb
input:
2 1 0 4 0 0 0 0 0 0 0 0
output:
4 0 1 0 0 0 0 0 0
result:
ok correct
Test #4:
score: 8
Accepted
time: 0ms
memory: 3668kb
input:
3 1 0 2 9 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
9 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #5:
score: 8
Accepted
time: 0ms
memory: 3760kb
input:
4 3 2 0 1 16 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
16 0 3 0 1 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #6:
score: 8
Accepted
time: 0ms
memory: 3776kb
input:
5 1 4 2 3 0 25 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
25 0 1 0 4 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #7:
score: 8
Accepted
time: 0ms
memory: 3708kb
input:
5 4 2 1 0 3 25 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
25 0 4 0 3 1 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Subtask #2:
score: 12
Accepted
Test #8:
score: 12
Accepted
time: 0ms
memory: 3728kb
input:
1 0 30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #9:
score: 12
Accepted
time: 0ms
memory: 3980kb
input:
2 0 1 60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #10:
score: 12
Accepted
time: 1ms
memory: 3912kb
input:
98 82 70 31 12 27 51 84 90 66 8 49 52 74 91 46 7 96 67 63 85 34 50 87 83 58 78 26 39 77 48 2 55 94 25 61 56 53 13 32 86 72 20 37 73 9 93 65 28 18 11 71 59 88 35 76 40 24 36 33 3 17 29 38 5 21 15 79 30 62 92 45 80 64 95 43 75 97 23 16 57 22 60 41 69 0 42 14 10 47 68 19 4 1 6 44 81 54 89 2940 0 0 0 0 ...
output:
2940 0 82 0 41 0 20 0 34 0 61 0 29 0 48 0 18 0 63 0 5 0 51 0 59 0 3 0 12 0 74 0 43 0 73 0 95 0 81 0 60 0 17 0 67 0 30 0 2 0 31 0 55 0 40 0 72 0 64 0 21 0 50 0 71 0 80 0 22 0 87 0 10 0 49 0 11 0 52 0 88 0 47 0 28 0 77 0 23 0 83 0 69 0 92 0 1 0 70 0 45 0 93 0 6 0 84 4 27 4 39 4 86 4 14 4 46 4 65 4 15 ...
result:
ok correct
Test #11:
score: 12
Accepted
time: 1ms
memory: 4080kb
input:
99 8 14 3 0 98 74 18 10 50 93 49 23 80 2 54 79 90 31 66 38 81 36 42 83 39 7 9 71 59 62 67 4 68 5 70 72 34 95 25 27 45 61 97 48 29 15 46 12 87 22 26 63 77 84 11 85 30 24 40 78 41 1 96 69 94 19 6 65 33 13 52 75 88 82 86 20 92 43 89 47 28 73 35 32 53 60 21 16 37 58 44 76 57 56 17 55 91 51 64 2970 0 0 0...
output:
2970 0 8 0 50 0 26 0 9 0 93 0 56 0 30 0 67 0 65 0 19 0 38 0 25 0 7 0 10 0 49 0 22 0 42 0 97 0 51 0 63 0 69 0 13 0 2 0 3 1 14 1 54 1 11 1 23 1 83 1 32 1 68 1 33 1 5 1 74 1 86 1 21 1 36 1 34 1 70 1 52 1 77 1 43 1 48 1 87 1 16 1 90 1 44 1 29 1 62 1 96 1 91 1 76 1 92 1 57 1 24 1 39 1 27 1 71 1 75 1 20 1...
result:
ok correct
Test #12:
score: 12
Accepted
time: 1ms
memory: 3836kb
input:
96 12 91 75 59 44 30 52 63 41 13 93 79 82 60 85 78 50 53 57 8 80 67 34 24 87 17 47 33 83 21 81 40 89 49 32 70 26 9 43 7 11 37 94 36 23 28 90 42 35 25 62 56 20 84 55 45 46 22 77 51 0 69 1 31 54 2 3 58 88 76 5 6 65 92 39 66 15 95 10 27 14 86 72 4 68 18 38 19 64 73 71 74 48 29 61 16 2880 0 0 0 0 0 0 0 ...
output:
2880 0 12 0 82 0 72 0 65 0 2 0 75 0 66 0 3 0 59 0 51 0 56 0 46 0 90 0 71 0 6 0 52 0 20 0 80 0 14 0 85 0 18 0 57 0 22 0 34 0 32 0 89 0 73 0 92 0 48 0 35 0 70 0 5 0 30 0 81 0 86 0 38 0 43 0 36 0 26 0 47 0 42 0 94 0 61 0 69 0 76 0 15 0 78 0 10 0 93 0 29 0 21 0 67 0 58 0 77 0 95 0 16 0 50 0 62 0 1 0 91 ...
result:
ok correct
Subtask #3:
score: 16
Accepted
Test #13:
score: 16
Accepted
time: 0ms
memory: 3784kb
input:
2 0 1 60 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1
output:
60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #14:
score: 16
Accepted
time: 0ms
memory: 3752kb
input:
5 0 4 1 3 2 150 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 ...
output:
150 0 4 1 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok correct
Test #15:
score: 16
Accepted
time: 1ms
memory: 4084kb
input:
96 7 15 12 95 11 50 20 42 81 29 58 80 56 71 63 66 44 6 64 39 2 22 73 1 24 27 69 28 45 25 60 61 5 94 14 65 9 86 68 32 79 37 3 57 34 35 10 88 76 78 21 93 19 53 84 52 4 33 38 55 62 67 77 41 31 48 91 49 51 43 90 8 87 54 16 17 70 46 85 0 75 92 74 47 36 89 30 13 59 26 40 18 82 83 72 23 2880 0 1 0 1 0 1 0 ...
output:
2880 0 15 0 7 0 66 0 42 0 91 0 3 0 18 0 95 0 64 0 23 0 31 0 1 1 61 0 67 1 49 0 78 1 85 0 89 1 26 0 69 1 43 0 57 1 33 0 94 1 72 0 87 1 13 0 71 1 8 0 81 1 92 0 82 1 74 0 16 1 44 0 34 1 14 0 63 1 41 0 37 1 86 0 30 1 60 0 62 1 77 0 46 1 10 0 58 1 38 0 68 1 51 0 93 1 83 0 47 1 88 0 59 1 55 0 52 1 19 0 39...
result:
ok correct
Test #16:
score: 16
Accepted
time: 1ms
memory: 3908kb
input:
99 28 2 16 95 73 6 30 90 18 46 82 69 59 4 40 49 33 29 66 86 97 56 22 96 38 35 67 15 83 44 36 72 81 41 76 47 34 87 65 9 92 57 0 55 68 5 32 17 61 50 14 19 58 24 98 48 53 60 45 12 39 3 8 74 88 77 13 85 84 42 79 51 94 70 10 25 75 31 62 27 64 1 80 78 21 37 7 63 52 23 71 20 54 26 43 91 89 93 11 2970 0 1 0...
output:
2970 0 2 0 28 0 16 0 83 0 33 0 78 0 41 0 62 0 57 0 8 0 60 0 18 0 39 0 66 0 9 0 13 0 46 0 4 0 32 0 73 0 81 0 70 1 79 0 27 1 15 0 49 1 50 0 14 1 40 0 92 1 54 0 98 1 11 0 69 1 42 3 95 3 91 3 20 3 97 3 93 3 26 3 67 3 85 3 37 3 87 3 63 3 74 3 10 3 82 3 80 3 64 3 88 3 52 3 58 3 45 3 5 3 6 3 30 3 36 3 34 3...
result:
ok correct
Test #17:
score: 16
Accepted
time: 0ms
memory: 3816kb
input:
99 52 0 59 91 38 87 65 75 48 11 64 60 95 71 62 79 49 30 47 56 33 16 94 8 78 36 13 68 9 35 74 77 80 24 15 83 28 66 12 51 92 84 43 40 4 46 63 57 17 85 42 25 81 14 50 31 72 34 70 88 67 53 6 37 44 45 96 69 2 86 76 55 3 82 22 5 93 39 26 41 98 7 27 1 20 29 23 19 54 18 61 90 89 32 97 73 10 58 21 2970 0 1 0...
output:
2970 0 1 1 52 0 81 1 7 0 75 1 5 0 87 1 19 0 56 1 72 0 3 1 91 0 90 1 61 0 53 1 14 0 62 1 6 0 65 1 45 0 46 1 63 0 37 1 66 0 96 1 10 0 64 1 44 0 4 1 38 0 12 1 95 0 73 1 82 0 27 1 68 0 2 1 59 0 88 1 54 0 50 1 42 0 43 1 40 0 92 1 89 0 18 1 47 0 57 1 34 0 15 1 79 0 41 1 84 0 20 1 33 0 24 1 78 0 26 1 13 0 ...
result:
ok correct
Test #18:
score: 16
Accepted
time: 0ms
memory: 3664kb
input:
4 0 1 3 2 120 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 1 0 ...
output:
120 2 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
result:
ok correct
Subtask #4:
score: 18
Accepted
Dependency #2:
100%
Accepted
Dependency #3:
100%
Accepted
Test #19:
score: 18
Accepted
time: 0ms
memory: 3812kb
input:
1 0 30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
output:
30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #20:
score: 18
Accepted
time: 0ms
memory: 3780kb
input:
2 0 1 60 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 0 1 1 0 0 1 0 1 1 0 0 1 0 1 0 1 1 0 1 0 0 1 1 0 0 1 1 0 1 0 1 0 1 0 1 0 0 1 0 1 0 1 1 0 1 0 1 0 1 0 1 0 1 0 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 1 0 0 1 1 0 1 0 0 1 1 0 1 0 0 1 0 1 0 1 0 1 1 0 0 1 1 0 1 0 1 0
output:
60 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
result:
ok correct
Test #21:
score: 18
Accepted
time: 2ms
memory: 4112kb
input:
481 264 22 307 266 238 227 68 26 13 12 384 162 410 306 374 311 442 38 407 310 280 308 333 146 326 381 367 110 190 33 141 468 153 393 157 415 229 75 276 392 349 348 179 445 317 64 78 20 323 257 292 395 129 259 165 398 151 219 14 116 338 188 243 61 150 84 72 340 155 133 459 464 248 433 124 399 177 62 ...
output:
14430 0 280 0 433 0 260 0 25 0 44 0 71 0 259 0 349 0 221 0 34 0 187 0 437 0 116 0 125 0 420 0 123 0 436 0 163 0 39 0 51 0 141 0 217 0 105 0 372 0 301 0 389 0 29 0 170 0 375 0 57 0 53 0 172 0 299 0 122 0 262 0 333 0 478 0 147 0 454 0 326 0 330 0 98 0 219 0 121 0 242 0 448 0 97 0 432 0 46 0 76 0 160 0...
result:
ok correct
Test #22:
score: 18
Accepted
time: 0ms
memory: 4108kb
input:
478 458 446 125 326 318 327 263 67 453 296 46 116 270 440 323 38 181 235 415 412 95 365 133 397 157 441 348 223 459 449 149 168 59 107 171 262 328 450 289 314 141 139 29 393 211 477 146 239 433 142 269 145 342 155 238 172 206 23 108 31 48 117 180 424 50 147 325 468 161 291 272 130 93 472 245 207 154...
output:
14340 0 448 0 294 0 31 0 91 0 244 0 381 0 126 0 431 0 260 0 420 0 85 0 184 0 46 0 127 0 190 0 3 0 68 0 112 0 468 0 364 0 58 0 262 0 214 0 216 0 384 0 92 0 69 0 318 0 109 0 175 0 374 0 443 0 363 0 470 0 86 0 282 0 151 0 232 0 312 0 423 0 292 0 22 0 244 0 8 0 236 0 424 0 27 0 379 0 410 0 193 0 43 0 39...
result:
ok correct
Test #23:
score: 18
Accepted
time: 2ms
memory: 4200kb
input:
496 426 495 20 100 83 50 3 247 94 52 290 45 179 160 344 239 270 133 492 398 131 476 271 436 69 351 401 494 111 76 393 432 431 207 53 350 24 288 278 359 413 253 181 166 186 336 35 173 209 448 352 364 188 434 203 38 439 32 328 285 213 112 47 128 136 303 49 180 444 132 177 114 287 475 161 483 14 108 66...
output:
14880 0 54 0 30 0 150 0 235 0 100 0 370 0 316 0 175 0 272 0 67 0 385 0 474 0 109 0 61 0 281 0 144 0 337 0 97 0 367 0 239 0 209 0 435 0 383 0 10 0 331 0 243 0 136 0 403 0 468 0 258 0 157 0 434 0 482 0 371 0 106 0 251 0 174 0 160 0 332 0 58 0 186 0 159 0 261 0 351 0 436 0 282 0 416 0 285 0 412 0 124 0...
result:
ok correct
Test #24:
score: 18
Accepted
time: 2ms
memory: 4336kb
input:
484 307 290 7 454 181 133 142 213 413 207 146 153 236 111 320 453 476 103 316 158 235 388 150 155 329 297 196 345 335 197 173 0 156 59 357 85 161 280 229 98 412 187 42 226 244 203 99 475 223 81 56 309 273 87 159 317 50 313 199 366 185 409 172 483 447 427 71 284 330 30 73 414 154 70 302 417 113 107 2...
output:
14520 0 76 0 350 0 216 0 264 0 408 0 113 0 213 0 2 0 7 0 285 0 367 0 341 0 423 0 146 0 10 0 307 0 31 1 206 1 122 1 120 1 188 1 250 1 25 1 297 1 482 1 400 1 290 1 321 3 454 3 404 4 181 4 313 4 340 4 333 4 117 4 331 4 252 4 243 4 52 4 175 4 452 4 59 4 366 4 33 4 443 4 324 4 471 4 255 4 256 4 235 4 283...
result:
ok correct
Test #25:
score: 18
Accepted
time: 0ms
memory: 4336kb
input:
496 145 300 465 228 235 186 373 183 142 208 278 11 410 286 392 245 44 470 211 368 283 240 265 120 30 68 71 158 263 356 439 243 27 311 86 134 201 33 319 371 254 181 231 89 214 435 113 59 48 151 317 143 320 195 377 426 408 303 22 47 149 330 180 175 412 140 102 204 381 441 50 258 232 105 266 52 122 423...
output:
14880 2 465 3 198 3 228 5 186 7 183 8 142 8 285 9 259 9 208 13 389 13 286 15 224 17 471 17 470 18 94 19 239 19 368 20 283 21 240 22 58 23 120 25 68 30 439 32 158 33 37 34 110 39 371 41 432 41 181 47 59 49 151 50 70 50 317 51 143 53 95 53 195 55 426 55 417 60 474 60 149 62 180 63 175 66 102 66 325 67...
result:
ok correct
Test #26:
score: 18
Accepted
time: 2ms
memory: 4440kb
input:
478 0 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 365 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 1...
output:
14340 0 71 0 207 0 377 0 381 0 139 0 27 0 33 0 407 0 160 0 350 0 274 0 392 0 5 0 190 0 123 0 89 0 303 0 353 0 329 0 281 0 215 0 78 0 472 0 19 0 126 0 323 0 291 0 302 0 162 0 245 0 98 0 420 0 368 0 357 0 467 0 182 0 83 0 167 0 426 0 326 0 38 0 334 0 142 0 101 0 44 0 3 0 340 0 194 0 25 0 112 0 189 0 1...
result:
ok correct
Test #27:
score: 18
Accepted
time: 2ms
memory: 4436kb
input:
476 0 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 129 91 92 93 94 95 96 97 98 99 100 1...
output:
14280 0 219 0 57 0 359 0 152 0 77 0 18 0 8 0 454 0 159 0 121 0 81 0 276 0 384 0 36 0 354 0 204 0 66 0 419 0 279 0 441 0 88 0 118 0 260 0 274 0 313 0 136 0 156 0 146 0 316 0 361 0 314 0 264 0 35 0 152 0 388 0 137 0 167 0 443 0 408 0 233 0 8 0 201 0 111 0 141 0 457 0 269 0 258 0 329 0 282 0 444 0 127 ...
result:
ok correct
Subtask #5:
score: 20
Accepted
Test #28:
score: 20
Accepted
time: 2ms
memory: 4020kb
input:
1800 530 1775 466 953 230 1179 944 752 990 1316 275 1029 158 152 1673 1706 172 115 599 1661 131 699 1112 454 551 1059 291 495 28 67 773 480 839 462 1210 757 879 285 439 3 1429 820 26 1023 942 199 356 625 1705 1421 144 1529 716 7 1485 1027 1599 696 517 1353 456 1389 273 1363 1414 1177 718 41 777 1621...
output:
5400 0 530 0 288 0 1704 0 346 0 1543 0 941 0 475 0 576 0 965 0 1091 0 194 0 1005 0 1734 0 1664 0 139 0 1736 0 1406 0 713 0 1157 0 647 0 770 0 1014 0 22 0 1112 0 1758 0 23 0 589 0 1724 0 1223 0 850 0 1354 0 492 0 1480 0 282 0 512 0 910 0 491 0 863 0 1015 0 980 0 1198 0 192 0 212 0 880 0 508 0 651 0 3...
result:
ok correct
Test #29:
score: 20
Accepted
time: 1ms
memory: 4244kb
input:
1950 1718 335 1071 714 1080 1828 1472 410 553 1269 297 401 1021 621 1763 528 205 1231 406 5 715 876 1474 1110 653 862 838 291 1092 549 955 1334 1044 300 1070 720 1877 484 1597 1948 1078 28 87 1193 505 1024 1259 63 852 960 633 1573 713 504 15 820 1852 752 1601 1168 471 1903 499 693 1209 1492 56 908 9...
output:
5850 0 1718 0 1717 0 688 0 1910 0 683 0 969 0 625 0 692 0 1932 0 1788 0 1452 0 580 0 1787 0 898 0 794 0 1648 0 551 0 884 0 518 0 595 0 1337 0 1890 0 591 0 1801 0 1364 0 198 0 1444 0 1883 0 1942 0 1464 0 265 0 1426 0 949 0 964 0 1336 0 384 0 1267 0 350 0 1867 0 854 0 1744 0 997 0 1491 0 987 0 134 0 7...
result:
ok correct
Test #30:
score: 20
Accepted
time: 2ms
memory: 3964kb
input:
1853 452 1299 444 1527 510 1801 34 1178 1589 1782 342 1800 735 761 879 999 1122 1772 236 566 1459 1256 1149 1498 1827 1027 715 1377 6 306 1811 950 500 890 196 1825 1568 1157 943 1422 475 1237 1792 1796 1363 1217 889 968 1439 1116 322 795 1088 1358 1833 96 118 543 1337 207 876 1144 805 215 1433 903 1...
output:
5559 0 569 0 282 0 1187 0 435 0 1645 0 928 0 1635 0 185 0 1596 0 1788 0 1017 0 869 0 254 0 1700 0 1016 0 378 0 1326 0 1411 0 1786 0 103 0 1271 0 176 0 1719 0 541 0 86 0 174 0 690 0 147 0 1145 0 425 0 613 0 1272 0 125 0 1743 0 622 0 838 0 706 0 1566 0 1839 0 628 0 119 0 1109 0 61 0 833 0 1835 0 1727 ...
result:
ok correct
Test #31:
score: 20
Accepted
time: 2ms
memory: 4320kb
input:
1957 0 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 1...
output:
5871 0 397 0 1236 0 543 0 1541 0 898 0 1699 0 1418 0 664 0 1507 0 306 0 637 0 1553 0 1784 0 853 0 701 0 598 0 1016 0 963 0 349 0 1020 0 1885 0 1137 0 1913 0 300 0 328 0 891 0 1639 0 1154 0 1894 0 1504 0 690 0 1205 0 225 0 1060 0 1121 0 1855 0 126 0 702 0 1270 0 449 0 1180 0 188 0 99 0 1381 0 892 0 7...
result:
ok correct
Test #32:
score: 20
Accepted
time: 2ms
memory: 4196kb
input:
1993 0 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 1...
output:
5979 0 632 0 1345 0 1482 0 261 0 1911 0 17 0 997 0 1067 0 1153 0 282 0 1018 0 838 0 879 0 32 0 434 0 1535 0 1968 0 595 0 1209 0 114 0 288 0 356 0 633 0 1101 0 1023 0 1708 0 1939 0 1528 0 335 0 1107 0 488 0 1420 0 270 0 246 0 1975 0 659 0 1434 0 1139 0 1511 0 763 0 1973 0 749 0 1378 0 1571 0 645 0 11...
result:
ok correct
Test #33:
score: 20
Accepted
time: 2ms
memory: 4248kb
input:
1935 0 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 1...
output:
5805 0 1547 0 447 0 1879 0 1074 0 138 0 1121 0 760 0 1482 0 158 0 1884 0 1853 0 322 0 1746 0 1194 0 1876 0 220 0 649 0 1556 0 1908 0 756 0 1221 0 1431 0 1528 0 488 0 1785 0 1479 0 858 0 1548 0 336 0 4 0 1683 0 1015 0 955 0 1157 0 226 0 1629 0 464 0 1928 0 1512 0 975 0 1171 0 1450 0 1273 0 800 0 948 ...
result:
ok correct
Test #34:
score: 20
Accepted
time: 2ms
memory: 4236kb
input:
1999 0 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 127 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 ...
output:
5997 0 1736 0 1626 0 548 0 1829 0 271 0 628 0 1212 0 259 0 47 0 1811 0 1739 0 1648 0 1611 0 673 0 156 0 53 0 503 0 1088 0 1501 0 1573 0 1693 0 1057 0 1082 0 1162 0 869 0 1372 0 1314 0 1139 0 74 0 1227 0 830 0 938 0 822 0 626 0 1800 0 939 0 1632 0 1317 0 1264 0 760 0 1130 0 1813 0 824 0 915 0 298 0 1...
result:
ok correct
Test #35:
score: 20
Accepted
time: 2ms
memory: 4040kb
input:
1901 952 410 986 1281 736 1411 1256 622 375 1423 718 1153 1238 643 120 1336 1097 881 1140 1395 1195 847 925 967 280 1859 966 360 815 770 634 1774 1359 1871 1589 618 991 571 1704 170 1548 1791 225 741 1561 35 1334 1632 203 894 728 1681 1849 22 1152 1719 701 1886 1037 1309 1576 993 1350 1643 893 1888 ...
output:
5703 0 1205 0 1680 0 205 0 1434 0 936 0 1287 0 1612 0 1639 0 1057 0 314 0 1526 0 1805 0 1350 0 12 0 77 0 696 0 1219 0 93 0 464 0 254 0 136 0 1127 0 1858 0 391 0 1870 0 1892 0 114 0 915 0 64 0 1530 0 1253 0 1768 0 1507 0 45 0 979 0 1175 0 828 0 1770 0 548 0 1812 0 773 0 339 0 1152 0 488 0 818 0 402 0...
result:
ok correct
Test #36:
score: 20
Accepted
time: 2ms
memory: 4068kb
input:
1931 1361 1614 1425 1627 1210 1778 166 420 1747 1792 1060 1914 611 833 1280 86 1754 1194 762 185 488 1368 1794 1153 1466 1689 1185 168 1622 1582 959 197 103 1809 1586 436 633 853 463 738 820 630 159 398 150 1370 558 281 1849 483 1691 350 1867 1871 1392 1791 1697 926 639 1865 1063 1726 262 1009 495 1...
output:
5793 0 425 0 1239 0 98 0 649 0 1387 0 1225 0 1385 0 822 0 467 0 253 0 1524 0 1200 0 383 0 1406 0 1440 0 196 0 1073 0 40 0 436 0 525 0 94 0 1681 0 795 0 948 0 1134 0 57 0 1813 0 1193 0 359 0 1552 0 1325 0 191 0 1689 0 440 0 218 0 1578 0 1403 0 1282 0 682 0 1192 0 610 0 960 0 1748 0 1918 0 1022 0 927 ...
result:
ok correct
Test #37:
score: 20
Accepted
time: 2ms
memory: 4040kb
input:
1938 428 1641 1051 1154 1556 814 986 237 1557 1082 84 1382 1823 1591 1779 1565 193 574 1683 1259 405 393 366 644 612 562 303 1567 997 1422 868 132 74 1508 1002 965 1752 500 1148 529 1119 1841 930 1608 1472 310 1435 261 705 908 588 1710 722 1427 1825 1256 1175 379 45 902 1861 62 729 1303 759 766 1022...
output:
5814 0 1799 0 1359 0 1624 0 790 0 1619 0 1778 0 547 0 1010 0 803 0 1489 0 359 0 1875 0 1339 0 1801 0 1023 0 1256 0 643 0 767 0 1436 0 1075 0 293 0 859 0 1277 0 362 0 265 0 575 0 621 0 1108 0 713 0 310 0 1447 0 254 0 1098 0 926 0 591 0 1174 0 976 0 1466 0 1160 0 1874 0 1216 0 709 0 962 0 1177 0 373 0...
result:
ok correct
Test #38:
score: 20
Accepted
time: 0ms
memory: 3876kb
input:
1997 1053 110 1738 1025 1245 1257 472 471 13 1215 1811 1371 476 1631 1028 892 1191 20 1323 868 435 1063 870 758 1538 155 1105 27 987 1345 1228 1473 452 1092 1561 1874 1417 95 252 565 1315 1389 533 1078 1259 1440 772 0 1588 1750 1451 644 659 1161 173 200 1680 1040 1827 1567 1069 12 1730 866 1493 65 5...
output:
5991 0 1053 0 47 1 110 1 71 1 1922 1 1471 1 470 1 7 1 471 1 1539 1 1647 1 1495 1 222 1 1537 1 1749 1 882 1 668 1 174 1 137 2 497 2 1692 2 1814 2 837 2 96 2 566 2 1555 2 993 2 917 2 711 2 1469 2 251 2 1326 2 687 2 399 2 937 2 1341 2 1599 2 1804 2 1887 2 1613 2 1961 2 661 2 1921 2 769 2 213 2 1052 2 4...
result:
ok correct
Test #39:
score: 20
Accepted
time: 0ms
memory: 3980kb
input:
1989 0 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 1...
output:
5967 0 141 0 1304 0 156 0 950 0 104 0 1139 0 1942 0 1642 0 420 0 697 0 582 0 523 0 999 0 1144 0 89 0 651 0 392 0 1649 0 455 0 881 0 253 0 1355 0 302 0 426 0 583 0 1965 0 1 0 246 0 963 0 151 0 1604 0 1513 0 2 0 1268 0 562 0 1738 0 681 0 1287 0 1540 0 1927 0 1895 0 270 0 1282 0 1025 0 368 0 1429 0 824...
result:
ok correct
Test #40:
score: 20
Accepted
time: 2ms
memory: 3964kb
input:
1961 0 1 272 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...
output:
5883 0 1616 0 928 1 142 1 1510 1 173 1 676 1 423 1 4 1 892 1 602 1 863 1 1900 1 1913 1 415 1 428 1 1636 1 390 1 1238 1 617 1 1469 1 1814 1 1441 1 1407 1 1512 2 272 2 1287 2 823 2 1227 2 1332 2 514 2 289 2 1327 2 39 2 1277 2 527 2 1805 2 1125 2 1681 2 455 2 1849 2 1634 2 1212 2 876 2 1600 2 128 2 151...
result:
ok correct
Test #41:
score: 20
Accepted
time: 1ms
memory: 3900kb
input:
1905 0 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 1...
output:
5715 1086 1471 1417 1779 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
result:
ok correct
Subtask #6:
score: 26
Accepted
Dependency #5:
100%
Accepted
Test #42:
score: 26
Accepted
time: 147ms
memory: 28852kb
input:
176900 167810 159384 90550 63101 76883 19925 161149 18578 132157 136198 141834 156609 167914 129523 2878 165972 95279 65282 30261 94853 37236 41515 166488 123502 141101 86565 153657 72526 396 92614 23189 1661 167567 100107 155037 35542 99140 171977 171544 123048 107611 71527 111368 88756 149185 9360...
output:
530700 0 167810 0 2442 0 129909 0 10456 0 139016 0 16821 0 25194 0 38200 0 72113 0 156123 0 73507 0 15987 0 8779 0 73201 0 41963 0 73728 0 104548 0 21921 0 132871 0 50262 0 67776 0 89205 0 59769 0 70978 0 43252 0 21251 0 99992 0 15545 0 108827 0 93901 0 86933 0 115184 0 90810 0 124863 0 153627 0 172...
result:
ok correct
Test #43:
score: 26
Accepted
time: 251ms
memory: 29204kb
input:
180601 172380 49504 27207 3423 41891 140536 126137 40192 90592 127987 124918 9486 152764 76028 76578 51283 40029 108361 93576 1341 36411 19763 103182 57530 103033 111456 32419 24822 89698 42054 101746 78793 103184 136054 135074 170297 146325 170251 21191 78975 68633 116257 103827 106102 162889 14512...
output:
541803 0 172380 0 168244 0 97345 0 179767 0 3522 0 53384 0 40305 0 116195 0 175196 0 22381 0 59886 0 97301 0 130722 0 7410 0 67366 0 123979 0 70729 0 74345 0 108401 0 144895 0 99570 0 111784 0 4653 0 49957 0 158304 0 125064 0 93420 0 48994 0 11819 0 113743 0 90386 0 82262 0 62865 0 57699 0 13626 0 6...
result:
ok correct
Test #44:
score: 26
Accepted
time: 295ms
memory: 30680kb
input:
190000 155277 81364 16113 73641 59637 140074 33594 60852 167804 149502 15249 35894 69246 132504 37548 26618 81511 141393 147548 24346 7165 123128 175784 74022 121283 80377 116823 111912 149688 96762 34103 104558 142346 82209 136360 40339 28418 119696 9573 42868 81005 59704 115658 173964 158009 43922...
output:
570000 0 24929 0 100694 0 189418 0 58805 0 76026 0 136403 0 57120 0 146246 0 169678 0 168718 0 97800 0 168932 0 124964 0 11407 0 130840 0 50745 0 145456 0 76077 0 36583 0 80304 0 101203 0 5037 0 36199 0 93504 0 175797 0 13073 0 71954 0 17679 0 149023 0 66056 0 147908 0 161697 0 57914 0 90673 0 5133 ...
result:
ok correct
Test #45:
score: 26
Accepted
time: 288ms
memory: 29272kb
input:
183960 0 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...
output:
551880 0 70716 0 1660 0 126387 0 112401 0 21346 0 114054 0 84684 0 37338 0 128165 0 128360 0 142541 0 31966 0 25550 0 95354 0 94732 0 40221 0 156232 0 99811 0 165090 0 75176 0 120475 0 118659 0 74594 0 148317 0 56341 0 147830 0 86783 0 157751 0 8137 0 85269 0 180077 0 109280 0 112381 0 30322 0 12989...
result:
ok correct
Test #46:
score: 26
Accepted
time: 302ms
memory: 31068kb
input:
195464 0 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...
output:
586392 0 173253 0 94113 0 162034 0 14265 0 30676 0 150705 0 137941 0 169410 0 32006 0 192227 0 32742 0 102655 0 139109 0 79733 0 138426 0 154237 0 26489 0 110097 0 165589 0 34819 0 150039 0 42527 0 93401 0 126310 0 11225 0 85662 0 41089 0 141999 0 80518 0 45618 0 172682 0 103349 0 179702 0 157590 0 ...
result:
ok correct
Test #47:
score: 26
Accepted
time: 323ms
memory: 31248kb
input:
199973 0 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...
output:
599919 0 84340 0 196359 0 15394 0 29122 0 158926 0 42552 0 42436 0 55224 0 50048 0 47547 0 12297 0 151637 0 117002 0 71956 0 161283 0 100182 0 132477 0 53164 0 91452 0 26091 0 121274 0 47043 0 192002 0 84330 0 81206 0 87213 0 119274 0 152447 0 48528 0 111096 0 18711 0 62685 0 78384 0 161629 0 58640 ...
result:
ok correct
Test #48:
score: 26
Accepted
time: 326ms
memory: 32224kb
input:
199961 0 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...
output:
599883 0 29373 0 185354 0 9441 0 28424 0 91480 0 46936 0 50414 0 150616 0 146683 0 31347 0 194970 0 153465 0 6425 0 72960 0 36812 0 117749 0 189064 0 48272 0 112544 0 119555 0 75301 0 174030 0 85714 0 128510 0 27376 0 108524 0 125153 0 91861 0 24800 0 181600 0 177735 0 112280 0 41217 0 49815 0 14141...
result:
ok correct
Test #49:
score: 26
Accepted
time: 111ms
memory: 30256kb
input:
193129 36602 123872 92038 45146 138692 111345 188441 38874 91571 40957 134717 29367 19348 43950 30107 169548 95423 20615 37890 24013 43534 56756 81846 81665 44142 51120 180128 191175 155099 72840 184568 93861 80314 90359 189897 714 93862 77927 44624 23382 86361 118437 115484 86518 100371 84582 12335...
output:
579387 0 123872 0 36602 0 75351 0 118305 0 96670 0 8239 0 78549 0 130070 0 147755 0 133972 0 28430 0 125631 0 110810 0 173048 0 191549 0 187123 0 12631 0 151269 0 60095 0 126436 0 180628 0 49989 0 12796 0 63684 0 9189 0 115200 0 114878 0 72029 0 56816 0 20461 0 114484 0 97406 0 94303 0 123170 0 1689...
result:
ok correct
Test #50:
score: 26
Accepted
time: 255ms
memory: 31620kb
input:
197082 28948 99935 148708 46451 122696 180672 62930 125162 102390 178828 36655 81146 108094 50099 58749 177353 187400 182745 51049 117239 46107 132994 126349 134844 20491 77064 156426 77316 106562 74474 181231 51810 115214 17483 98735 11537 154284 152530 31318 32324 150103 162145 377 111950 32190 84...
output:
591246 0 99938 0 192253 0 43742 0 141399 0 106726 0 108213 0 154464 0 150652 0 141412 0 42413 0 83091 0 28428 0 133901 0 30156 0 119878 0 89878 0 6036 0 79868 0 96289 0 160714 0 194545 0 124314 0 54348 0 161487 0 110223 0 935 0 158441 0 46458 0 142139 0 64310 0 40769 0 71778 0 131121 0 37120 0 64236...
result:
ok correct
Test #51:
score: 26
Accepted
time: 321ms
memory: 31552kb
input:
194300 41456 157650 130220 26552 100104 39688 171793 93878 171968 42386 15076 119236 116984 147030 178130 84543 41422 78012 62905 182069 27860 51578 123684 182555 79509 132548 171199 184307 163260 137221 40321 193521 22658 163921 153451 81135 146421 61739 37826 184064 100949 1221 27789 179291 15206 ...
output:
582900 0 142514 0 61225 0 62888 0 72867 0 132721 0 168693 0 150043 0 142216 0 33529 0 53828 0 108613 0 176542 0 146496 0 112623 0 161531 0 173290 0 101601 0 71684 0 119873 0 139600 0 80579 0 1400 0 104814 0 148573 0 108834 0 158849 0 117588 0 95617 0 155156 0 43412 0 141708 0 46845 0 158039 0 6165 0...
result:
ok correct
Test #52:
score: 26
Accepted
time: 305ms
memory: 30576kb
input:
191745 86160 177973 190897 101427 58207 52429 103273 57783 65873 49221 161353 23941 99019 125297 40852 27805 14133 40994 81091 37037 21432 47533 119915 102063 92390 79753 118310 157456 132054 38761 115430 33036 71721 54738 176381 140861 147078 36903 123109 71733 46877 173730 187571 7820 33867 26827 ...
output:
575235 0 149761 0 133874 0 48903 0 32598 0 69653 0 69866 0 133103 0 86091 0 147883 0 131482 0 48893 0 179643 0 38486 0 147359 0 122734 0 129326 0 124757 0 101216 0 78006 0 146017 0 8250 0 48287 0 66985 0 38657 0 67829 0 23117 0 110032 0 10340 0 24067 0 126500 0 147954 0 90641 0 124782 0 8308 0 49918...
result:
ok correct
Test #53:
score: 26
Accepted
time: 197ms
memory: 30060kb
input:
199993 196446 158206 8206 10499 39868 129031 121632 148457 183086 75548 11957 13065 15359 17847 118402 17577 159823 30468 24361 103231 121626 59655 36996 187439 89929 192793 20197 28808 16555 137308 105716 56425 198490 164384 8584 47629 83558 155060 148041 175988 3886 132588 15792 32028 104991 14846...
output:
599979 2 115682 2 72156 2 182472 2 150250 2 151858 2 189706 2 194693 2 32201 2 96457 2 121197 2 130163 2 174495 2 81536 2 61873 2 6167 2 93137 2 195196 2 189122 2 98240 2 128505 2 74736 2 179876 2 165774 2 9174 2 52136 2 48800 2 115885 2 197734 2 178923 2 34576 2 42031 2 26408 2 110709 2 95795 2 140...
result:
ok correct
Test #54:
score: 26
Accepted
time: 182ms
memory: 29128kb
input:
195962 0 143495 94457 139954 64590 53700 118663 178237 93365 76238 190312 47039 180296 27740 3019 173316 180035 69779 93653 122287 57697 21 119951 130009 15368 145558 129234 63611 55030 29 189665 107778 157921 184944 79827 118642 86050 82957 86225 39 29493 124696 114418 173586 84617 177846 170864 11...
output:
587886 1 148363 1 109813 1 74252 1 136930 1 19282 1 181952 1 151571 1 86790 1 24886 1 186627 1 12945 1 143495 2 94457 2 44996 2 3141 2 172675 2 27361 2 121696 2 174276 2 11804 2 195652 2 178904 2 99714 2 13662 2 109591 2 59834 2 8754 4 174873 4 171206 5 53700 5 179036 5 51084 5 102158 6 154066 6 159...
result:
ok correct
Test #55:
score: 26
Accepted
time: 284ms
memory: 31668kb
input:
194842 100154 140138 48998 98453 130678 177133 46195 8423 62509 72873 77452 122206 42181 60275 170586 2358 7988 89849 185284 193691 59370 185794 5218 23270 118843 81380 57130 150638 52947 187734 187310 168413 153988 136321 38186 163329 189331 126207 137943 84857 145378 167961 161479 69302 31915 1202...
output:
584526 0 100154 0 95131 0 27280 0 135143 0 189310 0 114024 0 162064 0 158889 0 170024 0 16894 0 11786 0 78028 0 136058 0 36032 0 14067 0 96467 0 11605 0 95869 0 89014 0 1170 0 37977 0 42369 0 27472 0 148051 0 188124 0 129510 0 27406 0 8918 0 119086 0 114970 0 150502 0 160262 0 116823 0 163885 0 2353...
result:
ok correct
Test #56:
score: 26
Accepted
time: 259ms
memory: 31020kb
input:
192864 140597 66570 121427 116752 26792 80717 160186 76426 8 89413 178636 77175 26030 47446 80214 37113 6890 186652 99224 16670 42488 160907 6475 13753 93053 55091 124543 86129 121212 126899 190219 159959 130785 94656 182197 40626 190748 71684 29400 127366 187275 144333 66541 159353 56469 45 46 1133...
output:
578592 0 11211 0 118796 0 6959 0 168482 0 91173 0 46925 0 117434 0 55197 0 48073 0 95459 0 21978 0 140597 0 189386 0 146572 0 97452 0 45410 0 141930 0 187027 0 67018 0 84077 0 81859 0 130357 0 147517 0 50599 0 99117 0 85250 0 81100 1 121097 1 140470 1 31965 1 109780 1 140587 1 161929 1 66570 2 12142...
result:
ok correct
Test #57:
score: 26
Accepted
time: 105ms
memory: 25812kb
input:
197205 69791 7278 144655 44140 100294 77302 123723 171433 104856 173242 169410 67899 36966 171145 136488 47079 48081 152021 59592 5911 4574 162108 173932 54582 62863 110098 59669 47193 129654 106687 152256 89688 184321 178761 50076 26558 84676 120349 3492 76839 83222 138603 78108 16086 42321 191702 ...
output:
591615 0 69791 1 7278 2 144655 3 44140 4 100294 6 123723 7 171433 8 104856 9 173242 11 67899 12 36966 15 47079 16 48081 22 173932 23 54582 30 152256 31 89688 34 50076 35 26558 37 120349 40 83222 43 16086 44 42321 45 191702 48 101863 51 152039 52 178223 53 17983 55 69114 58 109794 66 106547 68 86272 ...
result:
ok correct
Test #58:
score: 26
Accepted
time: 266ms
memory: 30964kb
input:
197131 84406 80027 110287 44746 131371 146934 42426 65970 150332 170783 65657 1953 162645 190993 109274 124958 51133 84371 52975 45289 169245 91663 107556 94239 181471 104596 71086 182854 165285 38597 66664 7262 124939 9815 82726 155117 130064 161982 165615 141978 54973 19100 50015 109085 117973 118...
output:
591393 0 84865 0 6792 0 85557 0 143935 0 84406 1 80027 2 110287 2 190021 2 36903 3 44746 3 71908 3 141115 3 141531 3 51917 3 113796 3 93697 3 17919 3 7913 3 40503 3 35850 3 35648 3 36297 3 158266 3 149751 3 117339 3 139557 3 35464 3 147867 3 165525 3 47070 3 186697 3 190030 3 166475 3 111662 3 8262 ...
result:
ok correct
Test #59:
score: 26
Accepted
time: 160ms
memory: 30888kb
input:
190716 70694 127495 127683 172932 35760 161055 89535 88848 86329 70488 159904 154657 123716 114250 17532 30359 18636 56168 87024 174259 84439 39232 146857 23700 109966 77964 87980 58575 44910 187918 44705 123208 129478 100467 24819 82211 54590 167945 186629 189101 150929 88606 28837 150355 60022 149...
output:
572148 0 70694 0 153598 0 179635 0 110171 0 69544 0 25660 0 179587 0 17581 0 83473 0 14426 0 29162 0 131204 0 169487 0 47050 0 19439 0 119597 0 83082 0 13869 0 121261 0 60839 0 6840 0 1188 0 52130 0 88728 0 104933 0 164663 0 182842 0 123293 0 87844 0 32204 0 133741 0 101282 0 31141 0 11814 0 79021 0...
result:
ok correct
Test #60:
score: 26
Accepted
time: 311ms
memory: 31180kb
input:
193898 85269 174015 77811 28051 118737 97733 40719 89809 27239 143398 80856 147511 63066 169396 188622 137055 75691 19603 26753 21153 38282 19883 184352 116056 74924 109097 83545 91598 188816 130408 12005 58299 179552 132499 184991 172525 19246 46965 82109 14127 45042 61971 139287 156790 158325 1053...
output:
581694 0 6871 0 160882 0 180276 0 124251 0 190399 0 172208 0 142570 0 183709 0 175138 0 62463 0 94287 0 154679 0 48859 0 87555 0 98730 0 79756 0 192522 0 185354 0 31142 0 70594 0 112563 0 104698 0 180605 0 62890 0 148541 0 90785 0 113935 0 12284 0 17002 0 77046 0 8136 0 9051 0 13384 0 89951 0 73530 ...
result:
ok correct
Test #61:
score: 26
Accepted
time: 253ms
memory: 30348kb
input:
193451 73331 167267 1859 26632 182171 73089 171348 172101 254 125155 89420 155531 85116 116670 120195 104715 81962 173779 54516 70099 186190 71017 67533 23137 114603 120956 148961 4395 85938 127836 173745 186046 50370 28206 98366 112565 66018 46642 74053 48767 7112 15058 176808 908 73048 45225 60762...
output:
580353 0 73331 0 157177 0 47256 0 165751 0 162115 0 62605 0 94110 0 15077 0 157074 0 80119 0 83835 0 146144 0 16069 0 125494 0 82592 0 121640 0 33269 0 165246 0 163495 0 38193 0 21518 0 68896 0 191585 0 54845 0 61732 0 62859 0 24910 0 154423 0 114377 0 181581 0 83603 0 79413 0 54400 0 130895 0 16522...
result:
ok correct
Test #62:
score: 26
Accepted
time: 294ms
memory: 30780kb
input:
191762 0 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...
output:
575286 0 177704 0 44227 0 166875 0 12124 0 5569 0 38929 0 71463 0 97938 0 56818 0 132714 0 69762 0 146041 0 100303 0 57625 0 56376 0 47577 0 20966 0 132700 0 181323 0 181310 0 110044 0 35724 0 20578 0 129650 0 66295 0 31312 0 112003 0 93384 0 66051 0 24714 0 129892 0 83791 0 49913 0 69707 0 84693 0 ...
result:
ok correct
Test #63:
score: 26
Accepted
time: 55ms
memory: 21732kb
input:
198205 0 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...
output:
594615 15183 139084 50474 152764 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
result:
ok correct
Test #64:
score: 26
Accepted
time: 242ms
memory: 30848kb
input:
199700 0 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...
output:
599100 1 114083 1 85188 1 181208 1 94264 1 131511 1 162374 1 42393 1 75521 1 183569 1 75473 1 171006 1 145688 1 60577 1 188206 1 75011 1 15958 1 60710 1 40277 1 160351 1 147929 1 162868 1 116831 1 76049 1 158820 1 113307 1 86465 1 71490 1 89569 1 156736 1 2441 1 162556 1 33956 1 15835 1 65282 1 8803...
result:
ok correct
Test #65:
score: 26
Accepted
time: 248ms
memory: 28900kb
input:
191786 0 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...
output:
575358 0 155833 0 81188 0 188507 0 117979 0 144030 0 45945 0 30201 0 85190 0 62542 0 38654 0 133688 0 38264 0 15394 0 47107 0 73089 0 8568 0 73790 0 4589 0 82396 0 168840 0 34461 0 156490 0 122669 0 177550 0 4930 0 148409 0 44939 0 117074 0 191106 0 11358 0 47066 0 150790 0 134179 0 92468 0 137928 0...
result:
ok correct
Test #66:
score: 26
Accepted
time: 254ms
memory: 29720kb
input:
193072 0 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...
output:
579216 0 17133 0 185092 0 109463 0 123322 0 1730 0 174436 0 154950 0 38491 1 85346 3 80232 3 96114 3 148443 3 184443 3 17289 3 182608 3 137317 3 77935 3 106571 3 162698 3 67334 3 123545 3 136733 3 78199 3 139849 4 190946 4 99137 4 151538 4 170722 4 6373 5 76681 5 79647 5 163501 5 100619 5 151707 5 2...
result:
ok correct