QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#326840 | #6414. Classical Maximization Problem | MistZero | AC ✓ | 304ms | 87940kb | C++20 | 5.1kb | 2024-02-14 08:55:26 | 2024-02-14 08:55:27 |
Judging History
answer
#include<bits/stdc++.h>
#define fi first
#define se second
using namespace std;
void solve() {
int n,lena=0,lenb=0; cin>>n;
vector<int>a((n<<2)+10,0),b((n<<2)+10,0);
vector<int>la((n<<2)+10,0),lb((n<<2)+10,0);
vector<bool>vis((n<<2)+10,false);
for(int i=1;i<=(n<<1);++i)
cin>>a[i]>>b[i],la[++lena]=a[i],lb[++lenb]=b[i];
sort(la.begin()+1,la.begin()+1+lena);
sort(lb.begin()+1,lb.begin()+1+lenb);
lena=unique(la.begin()+1,la.begin()+1+lena)-la.begin()-1;
lenb=unique(lb.begin()+1,lb.begin()+1+lenb)-lb.begin()-1;
vector<set<pair<int,int>>>g((n<<2)+10);
for(int i=1;i<=(n<<1);++i) {
a[i]=lower_bound(la.begin()+1,la.begin()+1+lena,a[i])-la.begin();
b[i]=lower_bound(lb.begin()+1,lb.begin()+1+lenb,b[i])-lb.begin()+lena;
// printf("%d %d\n",a[i],b[i]);
g[a[i]].emplace(b[i],i),g[b[i]].emplace(a[i],i);
}
vector<pair<int,int>>res; int ret=0,edge=0;
function<void(int,int)>dfs=[&](int x,int f,int fid=0) {
vis[x]=true,edge+=g[x].size();
vector<int>son; vector<pair<int,int>>bac; auto tmp=g[x];
bac.clear();
for(auto [to,id]: tmp) {
if(to==f) { fid=id; continue; }
if(vis[to]) {
if(g[x].find({to,id})!=g[x].end()) bac.emplace_back(to,id);
continue;
} dfs(to,x);
if(g[x].find({to,id})!=g[x].end()) son.push_back(id);
}
if(!(son.size()&1)) {
for(int i=1;i<son.size();i+=2)
{
res.emplace_back(son[i-1],son[i]);
// if((res.back().fi==6||res.back().se==6))
// cout<<__LINE__<<endl;
}
for(int i=1;i<bac.size();i+=2) {
res.emplace_back(bac[i-1].se,bac[i].se);
// if((res.back().fi==6||res.back().se==6))
// cout<<__LINE__<<endl;
int fir=bac[i-1].fi,sec=bac[i].fi;
g[fir].erase({x,bac[i-1].se});
g[sec].erase({x,bac[i].se});
}
if((bac.size()&1)&&fid) {
int fir=bac.back().fi,sec=bac.back().se;
res.emplace_back(sec,fid);
// if((res.back().fi==6||res.back().se==6))
// {
// printf("%d -> [%d,%d,%d]\n",__LINE__,fir,x,sec);
// printf("%d -> [%d,%d,%d]\n",__LINE__,f,x,fid);
// printf("%d\n",x);
// for(auto [to,id]:g[x])printf("%d %d\n",to,id);
// }
g[fir].erase({x,sec}),g[f].erase({x,fid});
}
} else {
for(int i=1;i<son.size();i+=2)
{
res.emplace_back(son[i-1],son[i]);
// if((res.back().fi==6||res.back().se==6))
// cout<<__LINE__<<endl;
}
if(!bac.empty()) {
res.emplace_back(son.back(),bac[0].se);
// if((res.back().fi==6||res.back().se==6))
// {
// printf("%d -> [%d,%d,%d]\n",__LINE__,114514,x,son.back());
// printf("%d -> [%d,%d,%d]\n",__LINE__,bac[0].fi,x,bac[0].se);
// printf("%d\n",x);
// for(auto [to,id]:g[x])printf("%d %d\n",to,id);
// }
g[bac[0].fi].erase({x,bac[0].se});
for(int i=2;i<bac.size();i+=2) {
res.emplace_back(bac[i-1].se,bac[i].se);
// if((res.back().fi==6||res.back().se==6))
// cout<<__LINE__<<endl;
int fir=bac[i-1].fi,sec=bac[i].fi;
g[fir].erase({x,bac[i-1].se}),g[sec].erase({x,bac[i].se});
}
if(!(bac.size()&1)&&fid) {
int fir=bac.back().fi,sec=bac.back().se;
res.emplace_back(sec,fid);
// if((res.back().fi==6||res.back().se==6))
// cout<<__LINE__<<endl;
g[fir].erase({x,sec}),g[f].erase({x,fid});
}
} else if(fid) {
res.emplace_back(son.back(),fid);
// if((res.back().fi==6||res.back().se==6))
// cout<<__LINE__<<endl;
g[f].erase({x,fid});
}
}
};
for(int i=1;i<=lena+lenb;++i)
if(!vis[i]) edge=0,dfs(i,0),ret+=edge>>2;
// if(ret!=res.size()) assert(ret>res.size());
// cout<<ret<<"\n";
// cout<<res.size()
vector<int>vec; vis.assign((n<<2)+10,false);
for(auto [x,y]: res) vis[x]=vis[y]=true;
// for(auto [x,y]: res) cout<<x<<' '<<y<<"\n",vis[x]=vis[y]=true;
for(int i=1;i<=(n<<1);++i) if(!vis[i]) vec.push_back(i);
// assert(!(vec.size()&1));
cout<<res.size()<<"\n";
for(auto [x,y]: res) cout<<x<<' '<<y<<"\n";
for(int i=1;i<vec.size();i+=2) cout<<vec[i-1]<<' '<<vec[i]<<"\n";
}
auto main() -> signed {
ios::sync_with_stdio(false);
cin.tie(0),cout.tie(0);
int T; cin>>T;
while(T--) solve();
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 1ms
memory: 3644kb
input:
3 2 0 0 0 1 1 0 1 1 2 0 0 0 1 0 2 0 3 2 0 0 1 1 2 2 3 3
output:
2 2 4 3 1 2 1 2 3 4 0 1 2 3 4
result:
ok ok (3 test cases)
Test #2:
score: 0
Accepted
time: 90ms
memory: 3712kb
input:
10000 2 -107276936 -310501829 419434212 585811870 -65754386 -491212232 381152038 897148193 3 -474045168 493506332 299114415 540203303 165808153 983551 -506936261 -694189769 766718170 -725540031 975267148 -593051087 1 -818952276 -762387923 584023914 -612401389 6 -77701228 -266484128 659434465 6322062...
output:
0 1 2 3 4 0 1 2 3 4 5 6 0 1 2 0 1 2 3 4 5 6 7 8 9 10 11 12 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 0 1 2 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 0 1 2 3 4...
result:
ok ok (10000 test cases)
Test #3:
score: 0
Accepted
time: 86ms
memory: 3780kb
input:
10000 1 999855386 999580905 999342928 999615227 21 999601032 999015398 999155628 999176944 999309856 999524434 999121011 999509537 999323572 999685730 999272272 999769606 999450559 999390758 999632027 999178534 999024993 999463838 999784856 999374197 999980525 999366771 999241260 999516879 999599548...
output:
0 1 2 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 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 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 0 1 2 3 4 5 6 7...
result:
ok ok (10000 test cases)
Test #4:
score: 0
Accepted
time: 85ms
memory: 3788kb
input:
10000 5 999984799 999981445 999958394 999984217 999994978 999981258 999955539 999938710 999936554 999963561 999907222 999907508 999938166 999941959 999910567 999986887 999901446 999961092 999994730 999963038 5 999916115 999962400 999948250 999940355 999954204 999920844 999928148 999990369 999978118 ...
output:
0 1 2 3 4 5 6 7 8 9 10 0 1 2 3 4 5 6 7 8 9 10 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 0 1 2 3 4 5 6 7 8 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 0 1 2 3 4 5 6 7 8 9 10 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 0 1 2 3 4 5 6 7 8 9 10 1...
result:
ok ok (10000 test cases)
Test #5:
score: 0
Accepted
time: 91ms
memory: 3924kb
input:
10000 1 999990146 999993828 999995909 999996353 56 999999851 999991179 999997250 999997987 999990590 999997316 999997350 999996856 999997034 999996236 999999396 999996897 999991180 999993309 999991265 999995185 999993952 999994054 999990210 999994471 999993201 999995893 999997170 999998971 999998201...
output:
0 1 2 1 76 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 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok ok (10000 test cases)
Test #6:
score: 0
Accepted
time: 91ms
memory: 3964kb
input:
10000 5 999999432 999999813 999999271 999999233 999999043 999999606 999999523 999999406 999999564 999999274 999999641 999999102 999999903 999999858 999999058 999999098 999999974 999999119 999999643 999999620 5 999999370 999999738 999999181 999999907 999999163 999999783 999999393 999999086 999999661 ...
output:
0 1 2 3 4 5 6 7 8 9 10 0 1 2 3 4 5 6 7 8 9 10 0 1 2 3 4 5 6 0 1 2 3 4 5 6 7 8 9 10 1 9 10 1 2 3 4 5 6 7 8 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 1 12 13 1 2 3 4 5 6 7 8 9 10 11 14 15 16 0 1 2 3 4 0 1 2 3 4 1 44 10 1 2 3 4 5 6 7 8 9 11 12 13 14 15 16 17 18 19 20 21 22...
result:
ok ok (10000 test cases)
Test #7:
score: 0
Accepted
time: 128ms
memory: 3988kb
input:
10000 14 -369804569 -904204119 526374829 -824374353 -127549933 -904204119 -68608787 929413707 -68608787 -363454459 526374829 929413707 693313139 -824374353 -127549933 -726843762 526374829 -904204119 526374829 -363454459 526374829 -409731440 693313139 -726843762 693313139 929413707 -68608787 -8243743...
output:
14 25 26 16 11 8 12 18 4 6 13 24 27 7 28 19 5 10 15 9 2 21 22 14 23 1 3 17 20 20 13 27 29 24 22 38 4 32 30 7 40 21 12 6 15 28 10 31 8 3 19 33 35 26 39 14 25 2 17 23 5 16 20 36 9 34 11 18 1 37 8 12 6 11 2 7 1 8 14 10 15 9 3 4 13 5 16 1 2 1 1 2 1 34 26 13 60 4 19 29 22 6 36 64 35 65 62 56 66 18 48 14 ...
result:
ok ok (10000 test cases)
Test #8:
score: 0
Accepted
time: 122ms
memory: 3840kb
input:
10000 5 -536123007 813600068 870612905 -192916365 -891077277 -192916365 -169354047 -86845158 -204880568 -86845158 -909192812 -613162163 -536123007 -613162163 602684169 -613162163 -909192812 813600068 602684169 -86845158 3 -296375355 579758813 -296375355 253508589 -296375355 -927878827 267975935 -927...
output:
5 9 1 5 4 10 8 7 6 2 3 3 6 5 4 3 2 1 5 10 9 3 1 6 8 7 5 4 2 5 3 6 9 10 7 1 5 4 8 2 5 4 1 3 7 5 8 2 6 9 10 2 6 4 3 5 1 2 1 2 1 13 4 5 2 21 3 7 15 14 12 18 19 1 16 9 6 26 11 17 13 20 23 24 22 25 8 10 4 1 9 4 10 7 8 3 2 5 6 3 2 3 4 1 5 6 2 4 1 2 3 5 8 5 3 1 10 7 9 6 2 4 7 6 9 14 4 7 13 3 10 11 16 5 15 ...
result:
ok ok (10000 test cases)
Test #9:
score: 0
Accepted
time: 112ms
memory: 4024kb
input:
10000 13 38708650 -400244265 805800882 -207412170 -922757982 569623504 330308285 -400244265 -922757982 193222226 330308285 -701148819 -28889088 854967427 284328781 704931219 -397379302 854967427 284328781 252366771 -699696493 -701148819 953729077 -601089169 -858131099 -701148819 -397379302 193222226...
output:
12 15 13 17 18 9 7 16 10 8 26 22 1 4 24 11 6 20 14 5 3 12 25 2 21 19 23 18 30 7 11 12 36 35 2 32 10 24 33 21 17 8 23 29 31 4 13 16 19 6 1 18 5 3 27 9 14 34 20 28 15 26 25 22 7 8 11 5 7 10 16 9 4 13 14 1 2 6 3 12 15 3 4 2 1 6 5 3 1 1 4 2 3 2 2 3 4 1 8 8 5 11 16 14 4 3 12 2 13 1 6 9 15 10 7 3 5 3 8 4 ...
result:
ok ok (10000 test cases)
Test #10:
score: 0
Accepted
time: 113ms
memory: 3764kb
input:
10000 2 -254673318 743896676 326182652 743896676 115024593 743896676 989112001 743896676 1 453875458 284043499 869627863 284043499 8 -68955663 625858753 -621253434 625858753 -315653340 625858753 -85160525 625858753 -592616333 625858753 114285020 625858753 618762545 625858753 524402507 625858753 1512...
output:
2 3 2 4 1 1 2 1 8 2 5 10 13 3 14 4 1 6 9 12 8 11 7 15 16 12 21 11 10 16 14 3 9 19 24 5 4 13 7 8 12 17 23 18 15 1 20 6 22 2 8 8 2 12 9 4 7 11 16 13 3 10 15 1 5 6 14 6 8 9 4 1 3 11 2 10 6 12 5 7 13 18 4 25 15 8 26 21 2 17 23 10 14 7 16 1 19 11 5 12 24 13 6 9 22 3 20 6 6 8 12 4 9 7 2 10 1 5 11 3 1 1 2 ...
result:
ok ok (10000 test cases)
Test #11:
score: 0
Accepted
time: 123ms
memory: 3976kb
input:
10000 10 -302093372 -991014187 542702243 714369751 -370626462 -991014187 -700169063 714369751 -982732066 -991014187 -763837020 -991014187 320477527 -991014187 290144737 -991014187 18975042 -991014187 -339021181 -991014187 -525462052 -991014187 290144737 714369751 -538375359 714369751 15943074 -99101...
output:
10 11 20 8 12 7 19 4 13 15 2 16 6 3 10 1 18 14 9 17 5 10 1 14 19 16 6 5 15 12 17 13 9 4 20 10 2 11 3 7 8 18 18 26 9 7 20 33 4 22 27 28 5 32 29 35 8 6 18 15 24 21 30 31 23 10 12 14 1 17 19 2 16 13 34 25 11 3 36 35 3 18 64 1 34 23 28 17 54 39 56 13 37 51 58 61 49 24 11 63 40 52 67 26 4 5 43 41 7 31 44...
result:
ok ok (10000 test cases)
Test #12:
score: 0
Accepted
time: 125ms
memory: 3964kb
input:
10000 5 192354975 -209258445 955055576 -209258445 286707627 -209258445 -574795734 -209258445 -305243931 -209258445 -629755833 -209258445 -337515030 -209258445 980285884 -209258445 501317910 -209258445 312382135 -209258445 24 272466007 467288536 -963587196 -778274012 240097765 -778274012 -926564605 4...
output:
5 4 7 5 1 3 10 9 2 8 6 24 30 18 6 20 29 41 24 39 42 31 22 35 12 17 11 13 3 9 27 1 40 25 46 32 4 21 23 47 36 43 10 8 44 14 26 15 48 7 16 45 38 33 28 34 5 37 19 2 30 4 14 50 45 26 24 52 58 22 6 16 59 20 30 37 18 56 54 19 44 47 28 27 1 36 31 42 49 48 46 57 11 17 53 10 32 51 39 35 33 9 29 25 60 12 21 2 ...
result:
ok ok (10000 test cases)
Test #13:
score: 0
Accepted
time: 107ms
memory: 3764kb
input:
10000 11 135813326 608040171 135813326 -96255413 135813326 -31734533 135813326 -423296887 135813326 999444876 135813326 946760362 135813326 -599331154 135813326 -441599790 135813326 233339336 135813326 -759375115 135813326 163868817 135813326 321091518 135813326 -402236877 135813326 625124369 135813...
output:
11 18 10 19 7 8 4 13 17 15 2 3 11 9 22 12 21 20 16 1 14 6 5 1 2 1 16 1 18 16 3 17 4 29 15 8 14 25 32 21 6 12 5 13 27 10 20 22 31 9 2 11 26 7 19 30 28 24 23 11 19 6 7 17 18 16 15 21 12 22 13 1 14 2 3 4 5 11 8 10 9 20 7 11 2 3 10 4 9 8 6 5 12 1 7 13 14 2 2 4 1 3 7 3 9 6 10 11 8 13 4 7 5 14 12 2 1 1 2 ...
result:
ok ok (10000 test cases)
Test #14:
score: 0
Accepted
time: 119ms
memory: 3740kb
input:
10000 19 321791336 -226466052 321791336 138757626 321791336 -613429828 944682716 -446131303 321791336 -927463006 944682716 280242351 944682716 229347131 944682716 155568891 321791336 389911916 944682716 72836839 944682716 -613429828 321791336 229347131 944682716 -927463006 944682716 138757626 321791...
output:
19 5 13 3 11 22 33 21 4 15 27 1 16 17 23 35 10 2 14 28 8 12 7 25 36 24 20 9 29 38 31 18 32 6 26 37 19 34 30 19 16 30 8 36 5 21 33 20 31 2 3 12 34 25 18 14 29 9 37 32 7 4 38 22 13 24 26 1 15 28 11 10 23 27 17 6 19 35 8 16 7 4 6 1 14 9 13 5 10 8 11 3 12 15 2 4 5 6 2 7 8 1 3 4 6 3 9 11 8 12 1 7 2 4 10 ...
result:
ok ok (10000 test cases)
Test #15:
score: 0
Accepted
time: 124ms
memory: 3704kb
input:
10000 2 414226098 -53411011 414226098 -515361565 -572270323 -515361565 -572270323 -53411011 36 660074753 623771687 -917096747 533975361 660074753 337851674 -917096747 -902052044 -917096747 846238046 660074753 197157825 660074753 533975361 660074753 626049519 -917096747 -108293477 -917096747 64055247...
output:
2 4 1 2 3 36 69 70 25 21 19 27 14 53 62 45 33 44 23 54 48 29 16 34 71 49 9 61 13 60 22 57 31 55 32 6 46 11 43 24 20 37 42 41 36 59 40 3 2 7 51 17 52 1 63 26 18 72 5 67 30 39 28 66 56 65 64 47 15 12 8 50 4 68 35 38 58 10 1 2 1 27 7 15 28 51 37 35 13 23 41 11 43 46 34 17 3 10 53 25 5 42 27 18 29 22 50...
result:
ok ok (10000 test cases)
Test #16:
score: 0
Accepted
time: 125ms
memory: 3828kb
input:
10000 6 475408912 -758469962 -99052258 -758469962 -716758863 872897211 -66386054 -170278720 388817201 174925294 -776227900 -285032873 475408912 872897211 -997698204 -236300379 -716758863 -85108619 -776227900 -85108619 -716758863 -236300379 -66386054 -85108619 26 879874105 877328664 -286895493 621573...
output:
5 6 10 4 12 2 1 7 3 9 11 5 8 26 30 6 37 43 17 52 15 48 45 10 1 23 8 20 14 41 21 49 11 5 26 2 42 51 24 44 22 12 50 29 13 38 3 47 35 7 40 33 16 46 32 28 39 25 4 18 19 9 34 31 27 36 4 3 1 2 5 7 8 4 6 3 4 3 1 2 5 6 21 14 35 42 41 27 31 9 33 15 7 28 32 16 20 17 25 37 29 2 30 34 10 13 1 5 18 26 12 6 38 3 ...
result:
ok ok (10000 test cases)
Test #17:
score: 0
Accepted
time: 123ms
memory: 3852kb
input:
10000 9 -980409638 -116749812 830791554 -690170434 984923479 323045898 984923479 -116749812 -197520273 323045898 -858897130 -43820432 258471629 -979749918 258471629 -690170434 -858897130 323045898 105960247 -690170434 -197520273 -841854666 -234415044 -116749812 105960247 323045898 -358435325 -202957...
output:
8 6 9 11 5 18 16 14 15 7 8 2 10 13 3 12 4 1 17 14 6 15 32 16 26 2 14 8 28 17 30 19 22 18 11 27 4 13 10 7 21 23 9 24 25 5 31 1 3 12 20 29 33 34 11 15 7 20 11 8 2 3 16 21 4 13 9 12 22 10 5 17 1 6 19 14 18 4 7 1 4 5 6 8 2 3 9 12 17 16 22 6 18 7 1 15 2 14 4 3 5 11 20 8 13 9 10 19 21 4 6 4 8 1 2 7 5 3 13...
result:
ok ok (10000 test cases)
Test #18:
score: 0
Accepted
time: 93ms
memory: 3944kb
input:
1000 45 840710004 395646135 -851514725 100215150 -423513540 -649756636 464326407 -482837664 -179781718 755995077 492651722 -268519233 367302062 -111998374 494634876 842096727 973319201 399526783 -703731734 -989899930 758934136 -959677785 -682507454 58961947 394206800 272218663 752299573 489795348 89...
output:
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 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15...
result:
ok ok (1000 test cases)
Test #19:
score: 0
Accepted
time: 94ms
memory: 4096kb
input:
1000 113 999827252 999728856 999923862 999631025 999319008 999580013 999333375 999174260 999509073 999545469 999194399 999278837 999715162 999728030 999881205 999764413 999917667 999953211 999651496 999869003 999693536 999169883 999545275 999786246 999969774 999735073 999892216 999697498 999954099 9...
output:
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 101 10...
result:
ok ok (1000 test cases)
Test #20:
score: 0
Accepted
time: 88ms
memory: 4008kb
input:
1000 16 999918424 999907758 999901558 999910407 999969229 999929343 999986216 999968746 999977167 999921267 999967186 999932634 999999615 999951539 999964903 999931387 999942189 999989158 999990624 999917294 999964661 999935732 999971224 999975496 999972707 999972034 999935060 999934824 999992448 99...
output:
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 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 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 ...
result:
ok ok (1000 test cases)
Test #21:
score: 0
Accepted
time: 89ms
memory: 3876kb
input:
1000 227 999994296 999999816 999998835 999994618 999998487 999991646 999995178 999996563 999996865 999996231 999990660 999996917 999995746 999998295 999993178 999995596 999994361 999991179 999990519 999991221 999996210 999992041 999991924 999992546 999991346 999991081 999998929 999995904 999992182 9...
output:
21 177 148 442 340 9 363 10 163 145 135 203 180 100 176 322 235 22 49 436 128 172 367 43 351 231 112 300 263 278 109 368 124 3 253 405 297 142 448 90 247 378 315 1 2 4 5 6 7 8 11 12 13 14 15 16 17 18 19 20 21 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 44 45 46 47 48 50 51 52 53 54 5...
result:
ok ok (1000 test cases)
Test #22:
score: 0
Accepted
time: 97ms
memory: 4056kb
input:
1000 87 999999138 999999640 999999785 999999342 999999914 999999854 999999771 999999416 999999011 999999479 999999217 999999865 999999423 999999937 999999684 999999301 999999323 999999399 999999071 999999949 999999226 999999154 999999770 999999090 999999778 999999735 999999034 999999517 999999803 99...
output:
23 80 54 47 165 135 139 75 10 92 132 104 26 110 71 70 6 86 29 166 111 142 155 15 23 124 51 131 149 83 27 16 162 112 72 65 115 12 98 143 161 168 158 164 159 121 56 1 2 3 4 5 7 8 9 11 13 14 17 18 19 20 21 22 24 25 28 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 48 49 50 52 53 55 57 58 59 60 61 6...
result:
ok ok (1000 test cases)
Test #23:
score: 0
Accepted
time: 133ms
memory: 4196kb
input:
1000 154 825004796 802565417 -88001579 364640592 778546546 -57508543 283686672 -57508543 473326798 -826011553 152069566 -577222261 528378065 -577222261 -56296909 -700802856 -711386984 953035370 -711386984 -577222261 895677144 -359290436 840183000 364640592 528378065 -752921798 895677144 -577222261 8...
output:
154 45 9 170 289 16 117 41 197 88 42 298 28 65 185 252 153 17 188 118 38 307 269 100 236 271 130 22 300 301 254 196 290 303 152 261 116 302 108 135 287 156 202 155 66 267 95 76 214 1 107 83 140 159 93 68 169 14 235 259 11 244 119 213 151 178 139 57 35 291 212 53 125 126 46 113 33 166 283 195 219 240...
result:
ok ok (1000 test cases)
Test #24:
score: 0
Accepted
time: 123ms
memory: 4280kb
input:
1000 63 859289659 -203061342 831821977 -778714404 640602188 478366497 205686723 -232506600 831821977 -498015901 -494818974 35295117 612307834 -234198721 612307834 -495294231 -898414633 476295237 995217164 -232506600 831821977 934046031 -441937174 432603845 995217164 938111737 874550198 -309423823 87...
output:
63 76 3 125 48 100 27 106 15 104 124 110 116 14 72 119 12 32 117 56 71 123 98 31 92 107 38 49 33 25 43 45 5 61 69 126 11 35 89 111 37 88 87 2 80 95 39 120 86 30 52 34 21 28 16 82 59 103 24 83 121 51 113 19 9 81 57 93 115 75 1 26 64 17 105 55 66 91 20 77 46 58 79 70 122 109 90 102 65 36 96 13 10 74 9...
result:
ok ok (1000 test cases)
Test #25:
score: 0
Accepted
time: 127ms
memory: 4200kb
input:
1000 83 -242219535 -952757420 753940135 -13368420 -180286961 -530756654 586180284 -625675517 -437809383 472014390 -242857851 -924097244 -382920283 -625675517 -630990620 -349004314 -242219535 122507147 208821889 -495849186 -736086757 -489441806 -996984615 -974276781 -275306966 -25109596 967186464 -65...
output:
83 154 139 74 13 83 35 95 63 81 145 50 106 8 93 7 105 160 134 87 110 59 67 119 138 65 16 21 62 38 86 124 2 77 3 49 20 72 118 25 115 89 40 111 10 45 137 75 82 73 96 129 76 150 85 43 53 22 133 157 70 108 141 149 52 88 54 99 41 155 164 18 80 64 79 29 15 103 14 78 102 94 47 34 37 92 127 33 71 132 9 36 9...
result:
ok ok (1000 test cases)
Test #26:
score: 0
Accepted
time: 109ms
memory: 3904kb
input:
1000 142 -28949259 975363136 -628367037 975363136 786525293 975363136 -8339801 975363136 868048337 975363136 208733157 975363136 -724415150 975363136 213367214 975363136 -686387505 975363136 -970451747 975363136 761135553 975363136 -551594491 975363136 -925080593 975363136 -243465321 975363136 -6722...
output:
142 251 70 79 113 10 29 25 269 188 13 66 172 211 101 192 30 35 134 123 80 112 124 244 61 277 143 153 191 246 22 88 194 236 229 232 37 163 7 89 54 53 9 201 118 15 218 144 78 2 248 44 69 121 209 182 23 137 174 47 110 12 85 262 126 52 257 189 84 234 238 130 240 55 231 224 56 267 21 32 49 117 24 278 206...
result:
ok ok (1000 test cases)
Test #27:
score: 0
Accepted
time: 125ms
memory: 4044kb
input:
1000 458 102600109 754726017 -66999931 951825513 -767202008 951825513 -845069119 754726017 -448344214 754726017 174342794 754726017 176530329 754726017 553731053 754726017 -69189351 754726017 -455330522 951825513 -261324017 754726017 809818684 951825513 745593756 951825513 -130095774 754726017 -2737...
output:
458 784 802 114 621 586 549 901 889 375 469 731 602 722 522 782 71 81 53 432 39 511 690 724 509 221 433 875 423 396 536 669 305 124 195 346 362 806 413 353 140 410 477 334 568 626 400 357 503 385 170 278 809 818 765 4 712 27 467 129 201 637 202 379 594 187 102 694 872 377 578 284 211 488 44 737 135 ...
result:
ok ok (1000 test cases)
Test #28:
score: 0
Accepted
time: 125ms
memory: 3920kb
input:
1000 273 638010636 -796267612 299279783 -796267612 321987052 -571635029 -388046291 -571635029 -491314021 -796267612 130988206 -571635029 32427063 -571635029 51875304 -571635029 -508530089 -796267612 269379692 -571635029 214241513 -796267612 720122947 -796267612 -678543365 -796267612 158504867 -79626...
output:
273 126 492 88 257 122 211 178 525 132 497 436 130 355 352 123 208 42 301 139 427 69 275 235 397 451 207 302 440 381 284 37 385 191 472 31 469 412 186 265 442 13 121 359 296 198 73 428 68 36 509 227 405 155 282 167 94 273 337 312 494 266 157 285 512 9 418 5 458 209 473 38 201 59 416 204 317 80 504 5...
result:
ok ok (1000 test cases)
Test #29:
score: 0
Accepted
time: 110ms
memory: 4216kb
input:
1000 75 429681826 802800421 429681826 -608943566 429681826 -787858696 429681826 507047252 429681826 485971873 429681826 -346306621 429681826 -612405192 429681826 -13671560 429681826 -816374335 429681826 513226316 429681826 892335083 429681826 -352600432 429681826 -556540475 429681826 -504699273 4296...
output:
75 95 54 133 47 55 28 121 147 79 9 22 139 71 3 145 140 119 85 24 132 76 7 2 141 66 26 13 78 67 53 81 120 14 87 144 69 34 117 83 16 41 105 17 72 46 116 94 40 12 6 74 44 106 27 84 51 100 108 111 146 114 70 142 136 35 135 62 25 90 33 131 82 149 107 127 8 118 43 88 77 42 31 65 143 102 60 29 75 103 20 49...
result:
ok ok (1000 test cases)
Test #30:
score: 0
Accepted
time: 136ms
memory: 4096kb
input:
1000 81 403001151 -229966312 -27290952 -941247950 -27290952 -872808715 403001151 -81762908 403001151 825473197 403001151 730971412 403001151 -886560490 -27290952 394200417 -27290952 808677817 -27290952 -961778274 -27290952 -245434545 403001151 318019109 -27290952 792029613 403001151 390473732 -27290...
output:
81 32 148 27 55 155 7 44 93 132 87 131 57 39 86 97 49 150 16 152 147 154 67 47 61 130 74 112 95 64 121 35 37 63 105 11 161 116 1 153 52 138 22 82 4 83 124 135 60 72 125 30 119 128 141 26 29 59 12 17 14 8 56 157 28 24 85 115 98 109 41 40 6 21 90 114 129 25 144 106 58 133 31 126 20 71 158 108 53 94 88...
result:
ok ok (1000 test cases)
Test #31:
score: 0
Accepted
time: 123ms
memory: 4116kb
input:
1000 257 -24981531 -524783010 -24981531 376842743 132542945 905111237 -24981531 -663183576 132542945 238995240 -24981531 -904084630 132542945 330336577 -24981531 -424310756 132542945 26224857 -24981531 573604180 132542945 -531956470 132542945 583434945 132542945 620552707 -24981531 -351085713 132542...
output:
257 247 276 291 427 59 441 453 168 6 107 227 359 385 376 243 350 416 228 27 124 449 250 170 207 428 92 245 110 175 154 169 117 185 193 274 460 463 78 485 61 487 128 442 68 241 305 103 365 335 215 248 22 88 52 475 253 292 151 31 86 106 58 479 311 266 229 373 509 71 139 105 340 304 507 109 85 356 465 ...
result:
ok ok (1000 test cases)
Test #32:
score: 0
Accepted
time: 130ms
memory: 3972kb
input:
1000 21 541263298 571344162 -338833794 258719906 814556806 571344162 749911951 -730958945 -737751671 400747496 880311857 -204125795 -555645311 -832036787 -338833794 -832036787 582588235 -915718735 -124654808 394321598 -202932677 571344162 541263298 -975674793 880311857 -730958945 -126659351 25871990...
output:
21 26 28 18 39 8 2 14 31 33 9 30 21 3 38 5 34 23 22 35 37 6 27 4 13 29 1 12 20 10 24 19 42 16 15 41 7 32 25 36 11 40 17 37 19 63 55 28 57 38 49 16 3 34 53 74 11 4 33 15 60 36 54 61 27 7 5 17 46 66 32 71 67 41 6 58 65 12 20 31 73 40 59 45 23 8 68 1 72 42 13 69 24 21 37 30 25 62 18 50 39 70 44 9 10 64...
result:
ok ok (1000 test cases)
Test #33:
score: 0
Accepted
time: 128ms
memory: 4220kb
input:
1000 82 620344713 761205214 564192450 -149133296 855072748 -725730286 -369866361 761205214 -126903403 123500699 521658307 -238068427 564192450 -575382074 424528213 639391487 160949070 -238068427 490683515 736060786 -861287945 -430077137 92203881 -414548921 -228263452 -161807552 -739623881 619906932 ...
output:
79 146 54 77 87 58 133 59 140 64 141 112 73 128 37 89 94 85 83 104 134 131 142 127 44 40 68 122 121 51 13 91 55 110 164 57 24 123 38 70 116 23 130 147 46 10 158 17 71 155 84 138 111 115 80 16 76 162 42 156 149 35 86 69 39 153 75 151 92 53 132 105 8 31 109 5 137 154 36 113 100 30 52 56 152 106 19 21 ...
result:
ok ok (1000 test cases)
Test #34:
score: 0
Accepted
time: 112ms
memory: 6256kb
input:
100 715 -716037174 449787280 -179603495 267807227 -85847745 -339745287 531498593 906672966 -65182647 -249655497 196101865 -917254384 569704541 175181937 408949063 -60772621 -471098833 -180592225 452882519 -173474204 518554869 504642822 -610596606 -43048739 -173418328 49620755 -490214353 129314297 -8...
output:
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 101 10...
result:
ok ok (100 test cases)
Test #35:
score: 0
Accepted
time: 100ms
memory: 5396kb
input:
100 1180 999939181 999607824 999877463 999501538 999725395 999197028 999578614 999669422 999691207 999388141 999798382 999350154 999515140 999686861 999804739 999722876 999059909 999779016 999988075 999795096 999394228 999790648 999357316 999130743 999834412 999146926 999533794 999419507 999164265 9...
output:
2 294 1956 485 2069 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 9...
result:
ok ok (100 test cases)
Test #36:
score: 0
Accepted
time: 100ms
memory: 5452kb
input:
100 10 999949463 999921247 999942779 999933524 999900374 999919960 999913527 999977190 999963539 999919222 999986393 999982382 999960627 999912715 999955900 999934316 999962876 999904282 999944172 999923360 999974177 999993968 999960412 999941887 999902083 999920318 999906832 999942948 999934454 999...
output:
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 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...
result:
ok ok (100 test cases)
Test #37:
score: 0
Accepted
time: 109ms
memory: 6364kb
input:
100 2795 999995625 999994422 999997406 999998890 999996073 999998910 999996365 999992345 999992211 999999534 999990826 999998894 999990827 999999648 999991569 999997094 999997323 999994792 999990812 999994722 999994392 999998879 999994441 999990381 999992051 999993298 999997822 999994423 999998285 9...
output:
1710 2563 926 78 2540 4669 1569 1970 530 4891 2589 5338 1024 3056 2582 851 3839 51 351 3380 5194 2356 4777 4263 1974 2538 4787 3834 2709 1959 588 158 1607 3344 1648 3887 700 1632 879 1159 294 1614 3252 2089 3987 4316 1870 4795 36 1230 443 3450 3500 5564 1756 1240 2785 4124 199 3580 1115 559 4535 284...
result:
ok ok (100 test cases)
Test #38:
score: 0
Accepted
time: 133ms
memory: 7236kb
input:
100 1005 999999258 999999564 999999716 999999506 999999057 999999959 999999274 999999385 999999562 999999714 999999749 999999926 999999159 999999330 999999060 999999408 999999218 999999582 999999097 999999761 999999853 999999231 999999424 999999841 999999744 999999186 999999400 999999073 999999445 9...
output:
985 180 1480 1306 808 1388 1560 934 360 827 1465 1290 3 1103 1120 264 324 516 1636 286 930 632 427 1530 1021 1516 363 1383 299 1127 650 1012 340 1947 295 1718 1797 1744 768 1869 969 181 989 879 354 1017 1619 1675 1876 625 1614 1441 414 406 1322 396 1788 1813 1559 1134 1366 1195 144 613 730 1836 1 19...
result:
ok ok (100 test cases)
Test #39:
score: 0
Accepted
time: 148ms
memory: 7128kb
input:
100 174 -958876330 -846470800 -796741809 -131152725 574295122 764287642 -958876330 -825762193 185468313 -971066749 -287559769 764287642 -904746093 -825762193 -438778854 -825762193 5267152 609322023 185468313 77515090 185468313 -131152725 -287559769 247199580 -491475497 260165013 719679418 -179087066...
output:
174 320 128 29 336 326 204 6 231 90 304 98 239 259 256 171 3 53 152 22 105 119 125 187 50 73 25 218 265 20 249 114 323 318 317 269 166 290 196 21 339 294 158 307 54 220 228 224 299 104 160 164 131 237 15 115 17 337 14 254 185 315 258 316 108 241 162 272 163 292 215 233 168 32 176 174 84 68 116 188 1...
result:
ok ok (100 test cases)
Test #40:
score: 0
Accepted
time: 153ms
memory: 7632kb
input:
100 454 292487349 -708917766 -446575764 -920302303 373857024 -525302786 236159958 -877034512 240035307 -28559828 -156425976 29793081 -683968223 -28559828 658545653 -892201965 -485118423 -349005511 -677465608 102959577 -241309351 -615266668 -857580103 -877034512 590882873 69859569 -961101806 -2385646...
output:
454 229 818 523 105 325 471 631 719 588 125 209 497 111 643 41 115 194 2 728 350 786 521 412 698 853 511 117 25 81 9 16 804 641 440 879 868 705 254 480 454 312 191 11 569 322 547 616 139 871 828 827 478 289 145 714 321 886 400 533 583 101 801 224 843 466 342 875 898 152 510 274 514 732 517 830 234 6...
result:
ok ok (100 test cases)
Test #41:
score: 0
Accepted
time: 128ms
memory: 6960kb
input:
100 140 229220674 878836488 -506767178 293730975 960642833 878836488 485659386 878836488 -225376185 16183205 -322465048 -460955536 -635701181 878836488 -578723152 374559636 956924322 878836488 -666563369 -550449367 -240963901 374559636 9519098 374559636 404598294 16183205 -188062738 467646265 937074...
output:
140 10 75 94 190 160 126 121 70 64 151 7 96 24 125 8 124 147 73 6 88 196 183 39 201 214 130 150 210 257 169 53 184 62 231 45 220 31 134 263 129 23 209 87 200 211 225 46 241 164 139 199 244 1 251 120 84 181 22 82 86 123 91 60 4 261 50 279 122 33 157 117 25 258 277 247 155 215 180 265 228 56 176 208 2...
result:
ok ok (100 test cases)
Test #42:
score: 0
Accepted
time: 120ms
memory: 5924kb
input:
100 453 -9728842 -879506383 723264369 -879506383 -617602947 -879506383 -883543546 -879506383 -365459776 -879506383 259863014 -879506383 -229024413 -879506383 -357634378 -879506383 45613473 -879506383 897413515 -879506383 142722904 -879506383 308356916 -879506383 -528467703 -879506383 45803942 -87950...
output:
453 614 339 627 863 556 902 669 466 260 300 438 350 80 157 612 333 303 604 35 528 30 390 645 698 54 905 147 714 377 523 417 236 524 100 766 84 290 850 322 435 492 873 138 567 171 424 261 242 538 4 853 291 870 374 410 238 359 173 800 632 755 727 370 777 886 516 656 796 189 906 251 268 154 445 542 731...
result:
ok ok (100 test cases)
Test #43:
score: 0
Accepted
time: 142ms
memory: 6472kb
input:
100 1681 -648014211 -216027092 -372352298 95789050 -678908480 95789050 -382412165 95789050 214922606 95789050 45021991 95789050 131451784 95789050 926607022 -216027092 -500711391 95789050 527775426 -216027092 860331657 95789050 -255764825 95789050 314154093 -216027092 -631103238 95789050 292792358 9...
output:
1681 1893 2580 3315 2510 704 1428 784 2736 2679 1887 1900 3000 440 259 2040 2375 2269 1933 2894 3189 1060 422 195 536 2043 165 2499 953 3162 1028 2403 289 508 2294 3231 1874 814 2383 191 1179 560 298 2044 2451 2718 1090 443 3311 1952 1144 3251 2826 1190 2518 2439 768 1537 510 93 115 735 274 2521 114...
result:
ok ok (100 test cases)
Test #44:
score: 0
Accepted
time: 132ms
memory: 5548kb
input:
100 476 218894313 -685169320 967098661 -16626457 -797375436 -16626457 955557493 -16626457 54133572 -16626457 -722192690 -16626457 791557373 -16626457 -208166285 -685169320 185917393 -16626457 -338707386 -16626457 49911294 -16626457 -359502368 -685169320 -359176146 -685169320 430103061 -16626457 -744...
output:
476 846 417 480 205 609 184 557 935 694 910 450 304 65 932 686 883 347 642 160 334 74 685 775 407 654 627 350 430 561 857 619 551 106 854 364 942 167 102 104 802 86 919 297 352 890 268 842 46 56 473 31 605 75 121 400 62 507 434 811 760 580 926 439 64 487 501 576 284 233 186 588 362 750 765 115 257 4...
result:
ok ok (100 test cases)
Test #45:
score: 0
Accepted
time: 115ms
memory: 5336kb
input:
100 1281 -7127937 -551225280 -7127937 -63829747 -7127937 50255920 -7127937 685959203 -7127937 -474730627 -7127937 205475943 -7127937 894868084 -7127937 -262984557 -7127937 858324856 -7127937 257534742 -7127937 -640954010 -7127937 -111367493 -7127937 892100661 -7127937 696606550 -7127937 136498536 -7...
output:
1281 318 1213 259 81 1291 1611 926 906 2219 1594 1702 594 1191 1363 1475 1016 592 309 1575 1661 36 324 1987 1138 2531 2208 1405 134 575 946 859 1176 365 1742 1800 173 2050 2395 379 965 426 1417 270 2466 1160 442 1533 1324 2528 52 1901 1898 1655 981 1996 1748 249 2182 1555 1321 1356 1768 2437 419 982...
result:
ok ok (100 test cases)
Test #46:
score: 0
Accepted
time: 131ms
memory: 5692kb
input:
100 2300 930979038 -865442548 56354538 569246647 930979038 209346563 930979038 -402151796 56354538 9788037 930979038 349210639 930979038 113353815 56354538 -508882748 56354538 -390359400 930979038 881411592 56354538 328521324 56354538 569030395 56354538 749112678 930979038 -492654973 930979038 -5806...
output:
2300 2815 1887 4095 3526 3238 4242 930 1499 883 4265 2960 2356 3460 2476 2966 1039 2154 2325 2812 1173 3418 1953 4206 738 1496 4583 3878 2243 1649 884 138 3349 1604 2004 532 716 2987 1234 3683 2189 2811 3216 2599 749 443 4392 3790 372 1049 1548 2315 1196 486 2003 271 1143 2838 1293 3610 1881 342 273...
result:
ok ok (100 test cases)
Test #47:
score: 0
Accepted
time: 127ms
memory: 5728kb
input:
100 393 484804995 -671233294 484804995 45381500 -343734967 483744892 -343734967 -678278044 -343734967 430018594 484804995 -536133521 -343734967 972761171 -343734967 188883545 484804995 291634094 484804995 161326893 484804995 43447237 -343734967 81642646 -343734967 905579532 484804995 -838456546 4848...
output:
393 385 484 272 256 587 397 86 610 516 707 292 523 307 596 399 648 656 244 753 715 305 390 33 199 617 191 598 271 652 449 240 324 740 258 111 696 606 525 144 284 375 645 364 498 456 435 206 14 608 374 641 82 154 239 267 56 274 159 295 494 642 442 304 728 270 246 241 58 25 706 34 21 777 467 554 671 4...
result:
ok ok (100 test cases)
Test #48:
score: 0
Accepted
time: 135ms
memory: 6872kb
input:
100 2245 257511569 -570888823 -409065975 834451934 972932318 -206332685 -220073979 -895107571 819486773 -206332685 819823298 -570888823 116295608 282026121 589205449 -895107571 -54658019 -895107571 987042524 -206332685 -196884689 282026121 -940822451 993058719 402874649 -895107571 633334868 99305871...
output:
2245 3050 1848 1582 534 2877 2746 1909 1914 3801 1651 2937 3877 1740 3311 477 447 1621 1241 432 1830 333 2033 916 1045 1843 60 4033 1523 3673 1531 3799 1594 982 863 3002 2356 2796 3548 223 1888 3729 1969 3049 2009 4326 4405 3979 3938 3542 3069 3256 3394 2963 2728 363 742 3299 459 4057 4171 773 3511 ...
result:
ok ok (100 test cases)
Test #49:
score: 0
Accepted
time: 145ms
memory: 5772kb
input:
100 116 -28349829 -267772969 -181233169 605639981 -221792554 885875755 -8847461 376377302 -527881168 376377302 -794286947 885875755 -442516480 365428090 60367949 59687335 844852200 -267772969 70152464 -267772969 -326579976 59687335 -382146420 885875755 -305012413 376377302 -255659827 495623398 84485...
output:
116 128 75 138 188 149 222 130 7 168 210 77 200 114 61 4 106 41 206 120 215 154 109 90 66 19 78 50 213 135 186 46 165 86 131 170 24 224 57 70 3 162 152 23 2 191 190 107 122 81 21 110 132 25 32 28 99 208 88 45 204 29 44 60 26 167 216 116 68 202 124 104 150 94 192 112 145 85 172 79 20 73 139 48 218 87...
result:
ok ok (100 test cases)
Test #50:
score: 0
Accepted
time: 149ms
memory: 13764kb
input:
10 10568 266619539 928993099 644537002 -163339024 -965315605 131093436 -873401839 -319727236 -682029920 -699502948 -857838819 -528950378 126750467 -72275669 623580094 410832833 287731394 -865265684 -71034303 515678565 -897514612 929674238 -794392375 895647772 811715826 600060479 640892543 -557248887...
output:
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 101 10...
result:
ok ok (10 test cases)
Test #51:
score: 0
Accepted
time: 152ms
memory: 16008kb
input:
10 983 999595593 999481588 999941833 999204986 999676040 999115470 999653065 999524261 999950018 999574889 999911879 999942071 999134864 999155033 999133604 999956453 999424191 999531479 999169859 999553795 999163364 999608732 999486991 999180185 999600255 999690901 999278724 999959357 999886640 999...
output:
2 931 1118 1034 997 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 9...
result:
ok ok (10 test cases)
Test #52:
score: 0
Accepted
time: 136ms
memory: 11320kb
input:
10 15236 999975325 999978324 999983228 999957461 999965056 999943264 999953829 999920806 999913911 999975263 999949326 999952997 999948654 999968342 999957007 999987426 999900723 999909965 999944389 999907733 999911075 999973513 999997298 999931066 999983079 999918568 999946266 999969557 999900152 9...
output:
6279 12245 21809 2368 30312 27410 30122 16648 25082 6716 172 23451 11875 16924 26552 14499 7930 4067 14142 6571 5413 8918 22110 20990 22535 24289 19369 7503 5512 7394 410 19556 5706 28621 13196 13939 19725 9324 21083 30420 26459 26563 6847 13797 9309 6890 17972 30055 29161 9772 4083 1127 5609 25672 ...
result:
ok ok (10 test cases)
Test #53:
score: 0
Accepted
time: 169ms
memory: 24272kb
input:
10 6642 999992808 999996636 999995238 999998603 999990460 999998357 999992495 999998027 999994992 999993315 999990663 999999307 999994510 999991024 999994319 999993024 999996312 999990447 999990590 999994561 999997748 999994786 999990918 999993436 999994457 999993851 999994234 999991647 999996595 99...
output:
6031 11871 3332 5607 1358 1647 9458 12133 9578 12529 3714 8106 1732 7834 10635 3599 11659 7441 726 6286 6289 9939 7039 2215 3809 3261 13010 1126 7070 309 1609 6966 13025 7315 808 3486 3946 7840 1071 9850 9933 9084 135 355 9489 8074 2486 9574 12531 447 2189 923 12333 4829 8704 8768 2407 7750 10788 42...
result:
ok ok (10 test cases)
Test #54:
score: 0
Accepted
time: 170ms
memory: 18524kb
input:
10 19516 999999707 999999837 999999488 999999818 999999509 999999591 999999991 999999026 999999356 999999726 999999489 999999193 999999038 999999298 999999881 999999157 999999344 999999162 999999160 999999113 999999139 999999582 999999470 999999327 999999742 999999921 999999255 999999737 999999216 9...
output:
19516 28840 14435 35480 36375 4352 36122 3410 3531 20750 24028 38919 33621 9339 1419 5508 25342 25420 24878 31810 7912 20700 28075 32493 952 13180 25275 33000 25058 29505 9373 18406 30727 7713 35625 32942 20132 38645 12115 10223 32104 20247 4379 35689 23146 24448 26010 6182 27623 24555 18751 6219 37...
result:
ok ok (10 test cases)
Test #55:
score: 0
Accepted
time: 183ms
memory: 17888kb
input:
10 14948 -170688734 833794743 949001579 224632065 -887648481 346146784 994218765 -808897932 948269970 764123696 24957273 562441566 -170688734 843621240 959643634 -354951661 631351081 -86364881 -9691567 824383620 -935916525 352437858 381851425 387057559 -6239193 951794229 450798340 -742525732 -394344...
output:
14948 652 21706 15400 11125 527 14008 16176 3127 8880 22043 9029 23062 10567 19275 7512 18287 9620 2523 11390 26196 10144 726 23359 5588 21540 15906 25386 2563 15407 21543 5276 28867 2645 8458 28537 3763 28262 14512 28728 6635 8115 2594 8337 2119 16868 25747 4305 2296 25377 20964 10056 3285 14167 10...
result:
ok ok (10 test cases)
Test #56:
score: 0
Accepted
time: 187ms
memory: 16976kb
input:
10 18275 46937162 -785699925 -512599977 -861792903 -732947245 771605479 -317815822 369273432 -478775873 211331712 -678678382 -401598442 -366699505 752973691 776710779 -7216385 -88306688 -190102574 328516250 -317225669 522217639 215990988 523904534 -256490677 540608168 493241721 620782210 -185524925 ...
output:
18275 15295 25551 4950 4212 7981 5604 13750 4761 11369 14943 9941 8123 28017 13980 13175 14867 23650 11590 36464 33507 32483 31090 16164 33547 10916 28884 34365 5463 29606 20879 33935 15965 25678 16283 25255 8294 15577 33675 17468 2628 34187 8064 32273 36485 5074 4360 34771 12122 28005 3306 6430 240...
result:
ok ok (10 test cases)
Test #57:
score: 0
Accepted
time: 178ms
memory: 16756kb
input:
10 390 -347835130 869197644 963535733 392603688 671237510 92351133 671237510 -703861232 671237510 423461538 671237510 369343656 671237510 980877320 -347835130 456099182 671237510 -311676199 -347835130 -886266831 -347835130 -257100015 -347835130 -637839633 963535733 -16989823 963535733 -821875052 963...
output:
390 210 707 777 148 611 125 368 698 70 272 324 372 415 391 627 428 634 366 560 416 650 61 10 431 637 668 629 66 250 408 453 755 104 402 454 302 745 129 139 370 653 47 233 736 670 14 475 561 379 85 700 483 487 223 193 536 763 710 203 596 462 239 423 4 550 41 625 378 235 529 513 314 34 253 580 544 201...
result:
ok ok (10 test cases)
Test #58:
score: 0
Accepted
time: 165ms
memory: 19216kb
input:
10 1285 637213737 -900998147 -356659628 -900998147 950244610 -900998147 -182671545 -900998147 -708950884 -900998147 -973866581 -900998147 -190878205 -900998147 135731649 -900998147 -125331609 -900998147 521939981 -900998147 976257311 -900998147 818237327 -900998147 705563706 -900998147 58565785 -900...
output:
1285 1838 1338 245 917 1188 2215 2518 1660 1999 1230 343 1787 1556 2467 2438 2021 556 858 131 1153 73 2506 1328 723 837 421 863 1813 909 2092 6 1080 2149 1023 2531 1592 2059 749 720 1548 300 1496 2013 208 2018 184 2497 314 399 2256 1778 2058 1668 250 1105 1171 2353 1310 1140 320 721 1735 1312 375 21...
result:
ok ok (10 test cases)
Test #59:
score: 0
Accepted
time: 182ms
memory: 23488kb
input:
10 5000 -188767223 -315528788 -987365245 -315528788 -106387689 135511984 127392808 -315528788 800721151 -315528788 146952905 -315528788 -323702728 135511984 411611172 135511984 872064533 -315528788 -40050336 135511984 119702024 135511984 -208480603 -315528788 679048782 -315528788 402900711 -31552878...
output:
5000 4675 9233 8065 4600 1541 228 7552 266 3063 4735 6297 2597 661 8484 5535 1978 2275 5123 9585 5029 3086 9657 3574 7631 6381 6450 2614 973 2786 5362 5653 2247 6951 1983 2369 3067 7689 7448 2392 3897 3571 776 6263 9853 7824 1816 4769 1490 785 4931 342 4299 6312 2630 54 1526 4593 3392 2538 2373 7942...
result:
ok ok (10 test cases)
Test #60:
score: 0
Accepted
time: 163ms
memory: 14676kb
input:
10 5892 25327490 -567979409 -735380777 -567979409 362509197 -518667355 380762791 -518667355 -325207607 -518667355 541910006 -518667355 36310841 -567979409 -726943590 -518667355 513235902 -518667355 289283655 -518667355 290421813 -567979409 892523351 -567979409 -894087744 -567979409 621832318 -567979...
output:
5892 9615 235 7794 6290 3690 9950 3677 5309 10042 10008 5683 9065 4249 7966 6833 2337 9628 3125 4691 4170 1742 11541 3000 10032 9599 9178 7990 8251 1634 4754 6897 6908 7396 10295 589 6353 6815 11542 11537 702 239 1116 2000 2304 6175 7128 4279 6868 10016 4269 5403 3411 7775 11090 786 8998 2723 6291 4...
result:
ok ok (10 test cases)
Test #61:
score: 0
Accepted
time: 158ms
memory: 19636kb
input:
10 7074 241731848 530211859 241731848 -112101076 241731848 -387299272 241731848 840407166 241731848 -519364921 241731848 -927667636 241731848 -12750799 241731848 446782229 241731848 -605995785 241731848 -360804301 241731848 -706630766 241731848 95158934 241731848 -937680624 241731848 162324777 24173...
output:
7074 11105 6133 2348 6041 6028 1466 1027 11615 3209 7046 9014 7246 9745 7369 4832 12989 2640 8596 12227 2450 2503 8228 8710 11496 9684 7346 8068 6810 13697 8060 5095 2963 11264 11584 2625 3739 3083 3572 6975 10549 2681 5712 12418 8017 7565 5881 4567 11469 5166 12323 413 4371 1259 103 7802 9110 10586...
result:
ok ok (10 test cases)
Test #62:
score: 0
Accepted
time: 179ms
memory: 22864kb
input:
10 729 867500722 -983664796 867500722 -428285695 -323742684 -171458916 -323742684 440597108 867500722 878319625 867500722 225023835 -323742684 -291982426 -323742684 568294497 867500722 327920686 867500722 -477580489 -323742684 310693081 -323742684 775098797 867500722 -334572408 -323742684 181766129 ...
output:
729 574 404 64 319 599 1125 374 1145 1098 1 1063 141 866 271 1243 1385 305 1210 888 132 1374 202 919 1069 688 334 1047 1400 332 1367 502 926 42 119 1447 983 939 242 1027 414 1429 996 803 335 213 733 1202 1088 1253 336 1174 1065 715 605 575 1366 1164 722 1382 772 749 558 237 1014 769 467 965 1120 114...
result:
ok ok (10 test cases)
Test #63:
score: 0
Accepted
time: 162ms
memory: 16220kb
input:
10 23890 -966926807 -783294985 -966926807 -231086723 -966926807 -827425532 -966926807 951590873 -966926807 -847083727 -322954521 -903547355 -966926807 395823002 -322954521 113620163 -966926807 442076584 -322954521 -358356830 -966926807 -416611206 -966926807 308206261 -322954521 -548371038 -966926807...
output:
23890 29453 30237 47713 16624 41649 47684 24829 1462 41768 6626 24632 726 39951 8656 44626 22406 44490 18770 38459 18370 30485 26650 22843 1958 30908 16641 12216 13184 17745 19013 16257 14924 15426 39335 44929 703 6226 24708 45191 8859 5977 24170 31310 44227 39361 14610 32350 45237 35209 25647 28066...
result:
ok ok (10 test cases)
Test #64:
score: 0
Accepted
time: 176ms
memory: 18300kb
input:
10 6461 164403694 719871079 -178686855 -505252945 820168812 419207217 -229478200 77799158 677361796 77799158 575661006 419207217 -697613489 -329650846 -362539459 -563403377 727778010 -563403377 -111787135 419207217 892586613 -329650846 664142990 435882783 -746057528 435882783 -484808272 -329650846 -...
output:
6461 2026 8194 9169 7964 4708 1304 4159 11566 11436 6650 2724 5130 7744 932 6139 12767 2766 5012 37 4900 706 7478 5821 2197 448 10261 12673 5978 1607 5322 8119 8323 6429 7854 4829 6894 2914 4249 2458 5949 12414 3615 12082 6226 4418 11606 7555 10032 8706 3647 11264 10060 1716 11953 6095 1164 10319 97...
result:
ok ok (10 test cases)
Test #65:
score: 0
Accepted
time: 181ms
memory: 14796kb
input:
10 14956 895706895 998300226 820538240 306140296 -445632195 597312604 -409959410 597312604 755346555 251251450 259123019 -176732314 701825202 -694016428 520061157 306140296 626248236 -236060915 321824154 -762678310 714689875 444441588 -774797456 597312604 4205823 306140296 104689711 -236060915 -9484...
output:
14956 169 2647 17446 11935 27912 20970 24178 10158 224 18828 17008 27919 25644 8693 25931 16592 26457 28833 24794 24631 29134 26658 22915 8440 13621 407 27606 6029 21046 12777 8769 18530 12397 17730 23045 23770 20147 23310 23644 11852 14993 666 17403 13984 9265 22891 3657 16631 27200 16954 13821 123...
result:
ok ok (10 test cases)
Test #66:
score: 0
Accepted
time: 202ms
memory: 47948kb
input:
1 100000 70720045 -382955525 180416482 414551370 -321808609 -148240525 -959621209 239890090 279590168 239445206 -672414454 -968764851 978907902 855176899 -927586531 -493246847 -87140549 -239161862 394302217 -390243883 747094712 472952985 437187652 834551586 -394349288 431373156 954522299 545636033 -...
output:
23 22866 143875 10401 178409 149552 66171 166114 67341 41051 182115 49949 149697 101362 45492 63240 180810 29229 14288 109193 154893 71595 187330 79976 198477 72594 62290 170770 117559 166828 49195 83326 83895 126162 171747 142744 64369 146324 134034 28428 29718 39525 192121 37584 9286 2141 144486 1...
result:
ok ok (1 test case)
Test #67:
score: 0
Accepted
time: 200ms
memory: 48204kb
input:
1 100000 999264440 999048423 999943779 999924927 999580357 999266886 999189670 999239640 999169156 999823062 999940080 999293014 999369020 999661305 999189323 999146694 999183801 999589407 999918625 999551090 999402308 999679213 999139826 999423045 999933104 999726376 999862333 999034393 999325582 9...
output:
30281 178475 191468 114440 196465 63279 190168 130183 21205 116391 35971 102771 47813 139621 72193 16926 118296 183876 10251 121960 63039 23328 43268 154654 21689 6949 154953 37057 86117 122427 157292 9993 82029 146063 149936 197810 74751 71241 150752 30432 130911 190501 18353 128030 124037 135817 1...
result:
ok ok (1 test case)
Test #68:
score: 0
Accepted
time: 241ms
memory: 74884kb
input:
1 100000 999975273 999973662 999943883 999925191 999951597 999989446 999981472 999903478 999927188 999993354 999922765 999970341 999935838 999925520 999910876 999943291 999965140 999987674 999960397 999922095 999924484 999966851 999904125 999916521 999937262 999938937 999920433 999985453 999952260 9...
output:
97922 125406 140899 192492 14952 155724 198996 82379 179539 113064 85165 104502 88076 64129 152638 98755 182842 63752 192477 13075 179701 45144 189720 146331 137126 38191 177079 71115 130575 34189 89556 126779 10394 28954 129399 22205 63431 37833 124606 174098 167173 116532 71417 159284 24249 165491...
result:
ok ok (1 test case)
Test #69:
score: 0
Accepted
time: 258ms
memory: 73472kb
input:
1 100000 999995621 999999670 999999969 999993086 999991515 999996627 999998034 999997733 999990010 999990951 999994345 999999518 999995768 999995576 999990755 999995308 999994356 999993294 999999258 999992963 999991118 999997972 999996805 999995493 999996557 999999418 999998617 999990595 999992992 9...
output:
100000 63357 108292 193115 21919 150876 181262 24674 121669 122792 119037 168968 9937 27580 106744 163803 191482 197902 50172 199162 44458 133802 20434 143105 1203 130579 5823 171875 50423 162781 77202 78933 197893 20762 122117 71423 66774 24075 195214 106812 20335 125100 19137 100845 74148 137316 1...
result:
ok ok (1 test case)
Test #70:
score: 0
Accepted
time: 286ms
memory: 69476kb
input:
1 100000 999999356 999999100 999999557 999999477 999999247 999999556 999999478 999999687 999999801 999999758 999999391 999999967 999999895 999999528 999999030 999999011 999999914 999999760 999999637 999999704 999999672 999999060 999999035 999999996 999999846 999999054 999999166 999999583 999999765 9...
output:
100000 159643 23892 83895 164645 96243 134836 86520 170915 115344 9382 62454 64371 135998 69723 56349 32565 52725 137885 168576 85623 84319 46643 14198 148223 196071 177343 93650 22195 14836 17607 116476 40908 89347 71701 75793 114745 22071 161857 73802 183318 93707 90945 120697 68478 141288 146978 ...
result:
ok ok (1 test case)
Test #71:
score: 0
Accepted
time: 277ms
memory: 69140kb
input:
1 100000 -547614182 905649186 -730348421 219289192 -138779779 -601726529 637290947 785577159 582877718 711339300 -747547194 -798832505 156167189 928036875 718258793 236208965 357417172 -293383985 383912089 713166152 233364698 -834647510 33321838 -637401353 -524918636 -271511728 -93689863 14541656 65...
output:
100000 186144 52310 70878 60526 17615 126403 125674 98497 131763 132998 25377 80569 164597 73737 96278 30925 195398 81754 130835 99439 65368 34415 95681 44484 72410 1831 170232 159966 127096 133911 112606 99350 101958 111544 4614 2749 134171 162179 6809 181169 60218 136 100917 92141 185519 47216 101...
result:
ok ok (1 test case)
Test #72:
score: 0
Accepted
time: 284ms
memory: 62816kb
input:
1 100000 -894716977 -12445007 -635179783 -174303206 -468545915 -376509646 7552798 863131659 -452959582 -848004313 240678088 -531526042 -479003636 561079229 -136051729 -523206668 -54957196 -969050964 202486976 -149599358 511163288 -909769354 -642881606 611633044 470598875 411065934 -70167418 -8251878...
output:
100000 92041 118408 5021 40920 88590 171644 110294 58745 144849 20973 59123 143111 82745 40983 115957 38642 159214 74093 163079 194457 47743 55825 42076 141206 141258 21720 20467 55013 154350 140479 23261 86983 187358 133770 23936 18369 17795 196202 129524 63343 128321 161669 148210 17654 136474 878...
result:
ok ok (1 test case)
Test #73:
score: 0
Accepted
time: 249ms
memory: 78844kb
input:
1 100000 798544191 -742903658 -344389104 -188662067 -571373110 161581382 -60448446 -916202148 -35781172 434088687 -786229077 240454644 -926134390 -986182581 17116411 -71954950 995069384 559207186 -65532930 -598813224 138636725 -620533705 781019115 572534456 -972340297 -182563578 -649565762 -18399977...
output:
99971 27597 13758 147818 138749 25059 57463 74977 27093 151058 166360 153642 35572 39655 30199 33664 156943 141351 188442 199805 69442 22673 69160 64580 116867 17242 130924 139476 60733 155427 31138 110832 56027 29252 166206 68548 25314 168517 13941 134797 81721 13294 18050 32500 161588 112400 16239...
result:
ok ok (1 test case)
Test #74:
score: 0
Accepted
time: 246ms
memory: 58660kb
input:
1 100000 339988059 -602619276 -336733168 -602619276 -3170495 -602619276 608750101 -602619276 125004008 -602619276 877505856 -602619276 -736053016 -602619276 80826707 -602619276 612582932 -602619276 -901063623 -602619276 -24681200 -602619276 -338686211 -602619276 786194401 -602619276 -639927824 -6026...
output:
100000 86520 179899 115928 34011 161915 148677 73440 150712 8995 62229 193121 166305 21517 170264 6458 147704 99794 16068 55891 89291 107081 128525 125488 158149 32892 174368 182987 153118 97620 129198 187740 172729 126562 102939 136823 62250 11101 173493 35241 167128 104005 3901 40447 173019 47985 ...
result:
ok ok (1 test case)
Test #75:
score: 0
Accepted
time: 264ms
memory: 57456kb
input:
1 100000 -152505637 741483922 608264196 -922967866 -978496364 741483922 517162535 741483922 -622471931 -922967866 -321900491 -922967866 69265759 -922967866 -580002960 -922967866 653169748 741483922 -40672330 -922967866 486195777 -922967866 301503518 -922967866 481889997 741483922 -351983361 74148392...
output:
100000 88523 158263 128238 86026 118398 188671 93526 184138 120009 137230 134591 102146 140342 161746 195856 92264 128780 176140 181103 142049 4197 69204 83877 124162 59208 49920 60210 10991 47332 61956 72901 8248 63112 33474 105828 96463 78588 34190 94133 109087 123249 105288 151973 15875 102859 42...
result:
ok ok (1 test case)
Test #76:
score: 0
Accepted
time: 298ms
memory: 57748kb
input:
1 100000 756868275 -358967603 -497301030 -358967603 649448245 -358967603 -887427985 -535956822 878399175 -535956822 108874606 -358967603 -489595415 -358967603 325972197 -358967603 498592984 -535956822 333245905 -358967603 -950621798 -535956822 -609666390 -535956822 -740046219 -358967603 -720433327 -...
output:
100000 48357 152724 123573 3482 81453 68512 159397 99862 174104 159511 107464 129023 174994 158454 103738 49044 84228 133756 26174 32517 133437 167544 57584 25025 116968 70 131003 59398 55477 155051 191358 142164 122741 137694 98489 173789 122505 81699 183731 61435 101003 60051 117183 131587 62468 5...
result:
ok ok (1 test case)
Test #77:
score: 0
Accepted
time: 241ms
memory: 58608kb
input:
1 100000 264643553 -937908082 264643553 361997414 264643553 -23850010 264643553 753755453 264643553 362490250 264643553 239156434 264643553 -577712364 264643553 -392015932 264643553 -411918647 264643553 -915806614 264643553 231314817 264643553 -909126325 264643553 -20860430 264643553 647884648 26464...
output:
100000 96733 44837 164539 156167 90187 133232 11415 64183 106125 36427 26293 95466 129488 141676 10605 137945 111425 45420 128774 180855 135928 125498 12728 22886 27397 38445 41640 112282 23288 101227 11044 47132 135972 21492 170564 178396 92827 21840 100538 125039 138717 96907 125640 162522 97800 1...
result:
ok ok (1 test case)
Test #78:
score: 0
Accepted
time: 237ms
memory: 57332kb
input:
1 100000 13210362 155232928 689159667 -465052240 13210362 21054014 689159667 867788821 689159667 -625434390 13210362 364078249 13210362 -911970949 13210362 937669731 689159667 -904647545 13210362 953420119 689159667 349328690 13210362 772099718 689159667 -718290541 13210362 -863735041 689159667 -306...
output:
100000 46382 164756 104363 134652 15911 158517 151014 7884 147059 94756 156631 142875 95700 145441 165010 135853 87869 124023 28461 70691 42826 40567 179365 186187 194857 138854 172262 78456 8669 60648 51378 33157 22023 135452 83936 93112 7970 91260 114401 106693 160639 145862 90496 43156 188169 799...
result:
ok ok (1 test case)
Test #79:
score: 0
Accepted
time: 291ms
memory: 57712kb
input:
1 100000 -530472390 452797636 12273745 -840226242 12273745 138841937 -530472390 397016016 -530472390 309315299 12273745 979552760 -530472390 286391147 12273745 -839888853 -530472390 468449806 12273745 27131915 12273745 144818527 -530472390 -97939838 -530472390 -221056215 -530472390 -238960974 -53047...
output:
100000 13127 26880 125438 101603 86635 7225 90603 168435 153736 7450 4047 37945 114779 189502 106490 182039 173511 103656 13841 171070 10547 56710 178815 57155 106909 154413 37225 72584 149478 132910 96977 178706 76769 160301 149227 86436 23608 89136 9377 190215 6615 148823 78600 118989 21162 157065...
result:
ok ok (1 test case)
Test #80:
score: 0
Accepted
time: 296ms
memory: 56672kb
input:
1 100000 -132158759 -454759942 -893626513 149724597 -756161772 -22802718 579977604 -454759942 430467545 149724597 363069127 -454759942 -355589432 -488155881 348983244 149724597 253076693 -258440137 391935158 862260872 211993426 -258440137 928069632 862260872 403296863 -22802718 -302606363 -258440137...
output:
100000 11371 163963 51559 81187 7988 99619 20026 182925 47095 66046 197785 7457 156174 98843 111449 192866 19154 89481 188566 41002 62613 9605 1199 12599 172256 117970 70890 57190 145604 119533 158274 73865 28619 18967 197528 94243 93993 48617 78750 6026 31859 131653 18447 85099 78638 52429 30843 42...
result:
ok ok (1 test case)
Test #81:
score: 0
Accepted
time: 304ms
memory: 57452kb
input:
1 100000 3959073 -767392567 109384252 941067269 -878847334 -620223817 607693789 483382967 998749160 43543215 259351742 -658880496 817766616 491476307 265921619 920072631 -95644194 43543215 -145143632 -356499617 -708593795 -254752752 292642145 865122144 -525142707 -376455870 653151805 -418942337 1803...
output:
100000 124555 181493 33007 108067 12462 121842 146621 7827 110771 122517 51763 109244 133036 139534 38919 34473 149605 33412 157783 192981 54432 110855 111930 94648 46122 47181 165144 66605 170206 160173 192810 167061 150316 116205 159316 6949 155767 125944 53440 156734 116508 36418 90504 77603 1549...
result:
ok ok (1 test case)
Test #82:
score: 0
Accepted
time: 186ms
memory: 48008kb
input:
1 100000 -574560244 663989471 147836313 776509735 -654179276 -456564123 -688242213 850544277 -769192009 -999278429 47264577 -474897694 661553314 -35586919 31425538 950985408 119252682 -364980087 -482879014 -842019980 562833870 -434563528 -602373511 -586582786 -597688232 794041526 -796369392 -9877200...
output:
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 101 10...
result:
ok ok (1 test case)
Test #83:
score: 0
Accepted
time: 197ms
memory: 48096kb
input:
1 100000 563809006 598960902 129945828 823924799 -921279427 -278305161 932151061 -615426941 253018906 394552155 -685768166 660779890 443266995 -129270185 314826112 -262631640 503785849 280786037 964401164 -60690178 -543715115 692212503 570497299 -501483747 -280889633 566370668 238345598 -30723398 40...
output:
10 176400 75494 42034 139377 9293 19963 27877 36282 77458 175690 38276 80047 22217 170163 171004 178064 75329 111455 9022 4978 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...
result:
ok ok (1 test case)
Test #84:
score: 0
Accepted
time: 191ms
memory: 47952kb
input:
1 100000 -250360297 -826731365 -132998833 434577984 -271597239 443621731 -568418163 -685113319 -351376307 -75720590 361691254 909826155 -611075026 748106801 -796334684 588036703 -192353104 -22634313 219167808 -130214795 153254126 -663910409 -706144293 -503074450 641195348 -471304455 952972496 722756...
output:
100 10195 98272 184454 41433 39717 78849 25537 167736 54468 36823 109947 53524 185978 192776 104053 40285 97231 19127 193351 74878 74939 138036 188634 84744 142135 110254 67658 83844 33982 46164 28251 83083 49336 550 7523 18109 31622 173767 106371 7126 5153 24510 6121 79102 191183 109683 142199 4790...
result:
ok ok (1 test case)
Test #85:
score: 0
Accepted
time: 201ms
memory: 48040kb
input:
1 100000 847984927 -235516053 -225657532 174062262 -864702235 849255554 -294101500 -395862766 308093550 262724017 -821802819 777396740 -166183219 -205295668 -925592163 -890396698 629939776 554098977 -597066517 -627025783 -488670566 -192742453 321766317 357807409 -56687363 -479719304 -346692362 43123...
output:
1000 54918 139058 17390 29765 67358 134476 15929 186991 20387 141329 122801 129793 62615 63500 122421 148151 84027 42750 120672 88771 141701 164545 153745 9285 20558 168719 129568 53902 15070 182593 44287 181718 33067 170064 39603 153221 37424 80291 49231 61968 6105 55335 55939 93559 1978 117087 317...
result:
ok ok (1 test case)
Test #86:
score: 0
Accepted
time: 209ms
memory: 48892kb
input:
1 100000 326229520 805825077 371787034 -612906440 -488264751 -793472428 184436425 366708550 -501110960 713157720 810357640 -567097567 -906732603 439225325 -340392868 -70415813 -189664219 -713969208 381067874 -619756834 674460096 668727994 618268128 -733873663 -622488527 -374494000 -696690105 -871302...
output:
10000 157135 17403 98477 88788 79270 195881 44849 51411 13182 28645 23220 125331 1626 42044 40635 8169 160365 196489 42116 74471 95498 189074 10619 188270 36759 146166 62440 58709 63551 68548 178213 56279 133722 81398 112382 176778 58789 158159 32276 132928 174890 48137 38346 400 146045 143456 59010...
result:
ok ok (1 test case)
Test #87:
score: 0
Accepted
time: 242ms
memory: 57548kb
input:
1 100000 107663449 169602795 -293408075 136298377 107663449 677735329 107663449 -133164493 107663449 -405477830 -973012232 136298377 40661124 136298377 107663449 -772028365 314648168 136298377 -951394425 136298377 107663449 252358019 107663449 84643404 107663449 661318647 -458027461 136298377 107663...
output:
99999 183700 8936 64954 63785 148914 121488 50985 21893 180540 66123 76217 138539 25653 141812 152072 146753 123427 155623 153977 113322 194151 54542 3008 168959 69840 175977 14093 86608 137370 187635 158264 84220 339 89820 12118 114391 171960 194452 119804 121278 157840 168154 197517 188182 87481 8...
result:
ok ok (1 test case)
Test #88:
score: 0
Accepted
time: 258ms
memory: 58424kb
input:
1 100000 621676756 -105718828 907764147 -105718828 -558728021 -105718828 -945909098 -105718828 -602870402 -105718828 104020243 -105718828 -283225325 -105718828 -188159226 -105718828 -15757119 -105718828 12299950 -105718828 382647230 -105718828 961198249 -105718828 142879463 -105718828 677630999 -105...
output:
100000 3877 74286 156766 74270 152476 110936 119045 191046 99648 38119 61667 61735 198991 188142 155043 121302 150298 2746 14883 76350 68350 7892 159576 86159 103845 32220 42739 105450 130434 71117 117799 176492 164908 122819 27048 78630 90296 149383 157208 110374 118923 171209 11270 31758 183554 17...
result:
ok ok (1 test case)
Test #89:
score: 0
Accepted
time: 258ms
memory: 58772kb
input:
1 100000 791929316 -452812205 -414545951 -452812205 -492402719 -452812205 -350798285 -452812205 308143137 -452812205 -270019539 -452812205 -837044713 -452812205 -855873836 -452812205 299134701 -452812205 -928378050 -452812205 949766412 -452812205 983552624 -452812205 -302417116 -452812205 -575137906...
output:
100000 43376 4308 71013 161050 29824 39048 69853 144338 71630 67223 97672 108385 191781 128355 157683 7616 44283 70991 32008 45594 197475 166358 195556 125944 180526 163182 6494 187540 88013 8471 97031 179738 45691 74392 73785 71789 173082 4299 115996 56580 197600 49585 67116 180106 89911 56486 1580...
result:
ok ok (1 test case)
Test #90:
score: 0
Accepted
time: 242ms
memory: 58712kb
input:
1 100000 -389700968 -854866948 157177186 -854866948 389548526 -854866948 359801591 -854866948 -404781586 -854866948 -756263865 -854866948 -874320830 -854866948 -860738544 -854866948 -494835614 -854866948 135417793 -854866948 878395153 -854866948 416627219 -854866948 50576116 -854866948 -877491066 -8...
output:
99999 141444 38613 14500 46885 30738 135834 3169 179389 88006 8007 25818 5663 98437 32625 65122 153872 50656 102828 31949 127290 71932 102852 77042 154318 177945 59769 8520 139551 23457 171270 123056 14198 22092 116254 100711 52674 67782 27101 110355 84551 26142 10232 23929 122063 21424 132313 14186...
result:
ok ok (1 test case)
Test #91:
score: 0
Accepted
time: 242ms
memory: 58648kb
input:
1 100000 -863878388 -228877853 556347609 -228877853 715519933 -228877853 -685414679 -228877853 121136094 -228877853 835184421 -228877853 2884225 -228877853 -632661834 -228877853 -376071163 -228877853 561924123 -228877853 104284355 -228877853 -832791265 -228877853 219285074 -228877853 -532813184 -228...
output:
100000 177731 112661 160772 195070 163739 8268 173716 29013 139714 125231 172603 171576 66417 138892 21054 41587 86793 101678 149428 73169 192655 183823 173876 45461 62266 58856 115698 106601 27754 26158 87984 3819 151050 71889 155191 117312 18298 101306 106274 76019 30661 186238 10960 15496 137775 ...
result:
ok ok (1 test case)
Test #92:
score: 0
Accepted
time: 261ms
memory: 58696kb
input:
1 100000 59979025 770483795 -687037673 770483795 -606503145 770483795 74265013 770483795 535504783 770483795 -353324202 770483795 -742185632 770483795 -880778420 770483795 445635005 770483795 -637158728 770483795 -798486264 770483795 -969460603 770483795 -183267551 770483795 219412933 770483795 4516...
output:
99999 84040 22323 100981 159098 10005 76741 134065 47550 115448 12369 133014 105950 156122 134211 102027 55051 128070 179443 23084 139207 33138 74718 189564 55415 187308 199551 94357 191402 100210 73069 32331 167504 52291 189692 16925 14615 120442 40634 136537 161569 135395 94940 33524 188217 10302 ...
result:
ok ok (1 test case)
Test #93:
score: 0
Accepted
time: 235ms
memory: 58664kb
input:
1 100000 -238717794 -675789740 892502036 -675789740 927735589 -675789740 265425600 -675789740 713089930 -675789740 975285688 -675789740 994425171 -675789740 377011822 -675789740 -469725428 -675789740 240456322 -675789740 -696780335 -675789740 13943625 -675789740 -105628955 -675789740 500932288 -6757...
output:
99999 29815 31762 147560 52036 54948 41465 186313 67959 44163 127171 97681 180550 54794 142354 113476 176026 43721 161445 15841 14859 164900 93810 170024 31611 157578 118093 90286 92044 141838 12700 24571 91687 130037 22098 4445 118168 107846 85130 82965 117224 96588 11257 150172 186007 110855 52186...
result:
ok ok (1 test case)
Test #94:
score: 0
Accepted
time: 236ms
memory: 58640kb
input:
1 100000 -721839075 207317220 198969479 207317220 721075181 207317220 816055383 207317220 129129955 207317220 578715168 207317220 938570372 207317220 -111023272 207317220 704310574 207317220 -29012555 207317220 -1124535 207317220 565642912 207317220 -164326927 207317220 269985061 207317220 -85992111...
output:
100000 54726 187608 156052 147127 93008 8764 188574 120059 94844 64342 82619 182974 188789 130761 196969 115342 110406 25778 196515 154406 120374 61976 128750 187932 35247 90352 199852 105677 31205 156407 168750 176258 199277 166601 45668 105061 23887 175520 115999 108426 66505 12930 209 106792 2038...
result:
ok ok (1 test case)
Test #95:
score: 0
Accepted
time: 230ms
memory: 58284kb
input:
1 100000 -394106502 -349602555 -214790523 -349602555 -773354523 -349602555 282532628 -349602555 908276613 -349602555 90866698 -349602555 547592286 -349602555 -771664838 -349602555 -459895994 -349602555 545210801 -349602555 348330065 -349602555 69245707 -349602555 -70850421 -349602555 -570400234 -349...
output:
96000 90137 162911 170069 40288 143110 103334 126676 159648 81406 30027 86785 102658 142919 176691 56529 170141 148266 251 93695 180600 136188 49587 156322 11770 176626 43145 89584 191932 4489 185292 169682 161412 50072 193670 51554 46267 81096 77052 98997 30925 44746 122409 101931 105941 94301 1118...
result:
ok ok (1 test case)
Test #96:
score: 0
Accepted
time: 233ms
memory: 58632kb
input:
1 100000 -212599148 -631411742 -212599148 -756608454 -212599148 -380727055 -212599148 -483620464 -212599148 -806607419 -212599148 464110295 -212599148 100221705 -212599148 426302083 -212599148 -770781036 -212599148 238123749 -212599148 652260340 -212599148 7400105 -212599148 -114015691 -212599148 26...
output:
100000 12296 161719 104908 151518 148853 146511 151543 120898 138665 96685 141246 117368 141429 103256 70908 34532 137290 90431 17082 132996 11608 6064 74664 75645 154790 181233 73181 87685 70051 182008 11724 54039 92993 95538 133085 113945 21264 8228 29933 174630 129882 24039 33381 192189 82253 977...
result:
ok ok (1 test case)
Test #97:
score: 0
Accepted
time: 241ms
memory: 58636kb
input:
1 100000 861172394 -290759846 861172394 752238765 861172394 -567950860 861172394 998044325 861172394 315984459 861172394 -627793707 861172394 -220676787 861172394 -268949003 861172394 -808244877 861172394 203040434 861172394 221600196 861172394 -142395895 861172394 723984474 861172394 25261585 86117...
output:
100000 2788 178318 114019 144782 52330 114790 144876 88980 155796 189810 101857 171251 65245 77178 133533 19637 103992 170569 36352 18075 5848 26672 132688 54259 159699 38349 38629 54381 4592 41632 162633 171088 135009 49392 199514 127214 45034 79416 142769 81959 162763 170297 173963 115179 132360 1...
result:
ok ok (1 test case)
Test #98:
score: 0
Accepted
time: 245ms
memory: 56992kb
input:
1 100000 499304870 -456067706 499304870 -526478356 499304870 -698177941 962157497 -209895866 499304870 603709976 194809397 -209895866 499304870 -622241129 295675965 -209895866 798750809 -209895866 499304870 -379083513 499304870 -835042147 499304870 -239680418 69233437 -209895866 -139695003 -20989586...
output:
92291 67646 140089 49240 124060 23815 108376 67692 145686 157455 125311 50318 85879 49853 86922 88915 73278 8728 133065 129411 57316 100124 81063 121289 102873 54042 34658 101941 185543 120689 47616 162469 183415 108232 132717 18549 15816 173601 186954 32997 124221 92906 172256 154432 4877 117806 60...
result:
ok ok (1 test case)
Test #99:
score: 0
Accepted
time: 228ms
memory: 54032kb
input:
1 100000 -858246250 615044192 -266041885 988276483 482718956 -318377373 -764628559 -906181651 -858246250 -473264095 142558228 706800755 -788262537 988276483 22746060 640859154 -990386331 988276483 -69851564 988276483 -858246250 85218196 218467508 988276483 -858246250 859181857 687573233 988276483 -4...
output:
67291 153281 105838 136491 126448 169347 139722 91281 78080 87220 12302 20154 31692 52690 47513 169240 12111 166475 37157 182760 45726 8926 191686 187646 31436 51513 31295 166765 42028 169233 93283 177783 61751 22018 34459 145853 30527 89097 133940 63661 60253 58845 115880 192468 41097 37924 21762 1...
result:
ok ok (1 test case)
Test #100:
score: 0
Accepted
time: 217ms
memory: 50628kb
input:
1 100000 -150551753 452254502 -589126107 -154864988 -774655110 -258862906 419458744 436149924 832748324 626049996 -150551753 -842016341 50222854 48805382 -533365798 510362787 417401571 -205386056 567574644 -154864988 -813149443 794441936 -299793018 -154864988 770796798 807259574 -150551753 345399056...
output:
32291 122729 163258 179530 197115 124891 75944 193355 12112 717 34324 51215 83008 40569 114323 75798 105105 34664 39959 34686 95131 127819 36503 168360 161289 192310 184587 62322 24188 146587 189247 187352 195548 6110 135047 132541 130821 68696 21677 166131 125540 125763 154573 149141 189397 53584 7...
result:
ok ok (1 test case)
Test #101:
score: 0
Accepted
time: 210ms
memory: 48448kb
input:
1 100000 285908168 272049532 -886964145 -569780386 510905036 729082089 -980711479 -610409392 -374956972 -629812402 247564824 -494813970 -424829969 808435687 -596358126 293552786 -231573518 593358144 -206584506 -197027197 788863793 -320825254 -80636341 343699149 865833827 -126707889 -264031756 -99178...
output:
5111 172030 117174 195577 45558 84297 7884 58827 129631 168918 154456 170236 69299 163683 29157 93459 109077 181106 116535 41342 96789 114440 172240 54964 72546 65913 26468 35471 171421 50045 1670 97324 9610 32884 185868 163463 40161 173569 80659 47159 67450 73569 33143 127483 168454 190552 8761 175...
result:
ok ok (1 test case)
Test #102:
score: 0
Accepted
time: 199ms
memory: 48016kb
input:
1 100000 565553778 -960078095 363313784 637330036 813479302 196734774 -774652802 -191779344 -980564833 -172476596 97721308 -222616457 -585108481 -816071325 384348686 -771714186 399507870 923194801 775022324 -521366927 112774804 -456550819 596715515 -351906433 -733278086 945383835 -295767823 82342179...
output:
20 37956 49656 121095 97944 177089 163883 47471 38908 172056 18784 174877 123206 56684 183908 129376 174549 145455 159601 28985 149668 105384 121584 77333 75404 19683 28427 85752 154987 185622 129239 151683 7087 185310 12330 62896 17587 117515 4722 180069 18839 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16...
result:
ok ok (1 test case)
Test #103:
score: 0
Accepted
time: 200ms
memory: 48096kb
input:
1 100000 832414397 -191973279 799697814 453822080 472902980 355661811 773889737 -237095042 139066161 -168030962 -200818308 -659210292 591819947 -690219588 -894723232 -724129935 309100621 -442280293 601783531 -629714403 -518284237 -502069854 -324318938 -999351826 -445350259 -776355044 579496048 -3535...
output:
200 11425 26880 106319 184481 49749 51891 35969 106381 114007 31157 141363 80666 51873 185431 85772 9455 10044 42818 108747 91672 78075 36582 90234 151937 96142 7634 75881 116841 72799 95243 185002 21599 102893 107090 181657 156912 87657 41092 72099 87188 173090 142512 43487 37521 170508 107654 9159...
result:
ok ok (1 test case)
Test #104:
score: 0
Accepted
time: 195ms
memory: 48200kb
input:
1 100000 316081038 264919400 418308983 754756042 -672507100 -504831259 347176006 -475455422 -464074155 250593938 -689733050 -558992193 165084421 594791692 756992395 93538486 601928596 425487522 -948968175 -775787311 642279460 -97489081 949706854 134386823 -573515957 -691035427 686110259 935429550 -3...
output:
1984 80730 96380 24236 61773 97716 87163 159964 97495 69966 191349 138832 29008 184633 50507 74032 51328 57277 42408 28127 87535 149903 127974 116733 149426 184738 123171 31468 102530 130452 147974 145932 41622 173568 154604 45469 47364 62020 141445 138166 120170 50448 53815 36175 149534 100906 1803...
result:
ok ok (1 test case)
Test #105:
score: 0
Accepted
time: 193ms
memory: 48124kb
input:
1 100000 889766050 -900215668 -785435069 932780511 -593598392 -319579936 -819907899 -897600509 -163102947 369765636 -287328155 456835725 -903811491 57154208 -354611840 883364613 475188396 746218920 -813614969 540734211 824473110 591677255 -509397296 458247192 468251135 -745120799 508553265 422069900...
output:
18252 30867 130239 108109 73253 197305 1594 34334 158030 196652 163997 163994 159253 172697 46749 59728 126589 39390 164895 59065 29061 83017 59384 94457 148085 16527 78130 49467 88046 10070 150632 37595 29840 168100 124563 153543 182835 80570 132009 128884 178092 96601 11857 125624 83565 180367 496...
result:
ok ok (1 test case)
Test #106:
score: 0
Accepted
time: 244ms
memory: 71120kb
input:
1 100000 569138929 623081181 595176935 -231729559 -353366942 -403863070 910926966 869119211 394470687 778639413 603585935 114468456 -834453070 52891615 988978359 457907555 -126372552 606236966 -965264313 -667974370 933978631 902269405 -462709387 -210009622 715607853 -386237572 -671683002 152885468 4...
output:
99999 13490 98010 193292 96209 169402 166063 108676 63428 124680 28013 192909 187854 157168 194265 131652 77464 173433 40659 170823 94194 144147 198023 97071 68401 121838 11710 113077 147949 145431 167551 97702 10456 64262 91102 86987 128430 13225 120166 177607 49797 138907 75436 59274 137791 35955 ...
result:
ok ok (1 test case)
Test #107:
score: 0
Accepted
time: 239ms
memory: 57696kb
input:
1 100000 -545580238 206875231 -334278490 284778314 -577688466 532471873 -696161358 -260770669 -543552171 609399466 -248845812 281374889 604662925 947696452 815211151 -792551232 -726993196 -873648831 -806959352 -523234454 451106708 -525149528 196005170 210990094 7637155 927805109 -471891793 91423437 ...
output:
100000 188098 51171 155200 23477 150635 68504 7628 97809 46671 137262 187694 4680 178358 140964 194410 114801 93980 3464 168480 804 58544 127130 73340 12945 91249 155532 188020 75846 165246 23047 72227 110749 156878 47532 135529 167763 102153 189248 174135 33227 113402 56066 63152 106293 14185 19785...
result:
ok ok (1 test case)
Test #108:
score: 0
Accepted
time: 243ms
memory: 58696kb
input:
1 100000 289524496 -156648931 477259193 -156648931 -940874730 -156648931 -678074509 -156648931 430778344 -156648931 314792323 -156648931 590595199 -156648931 336769789 -156648931 -952491382 -156648931 569800304 -156648931 -334619798 -156648931 745977166 -156648931 -939318247 -156648931 313727017 -15...
output:
100000 43587 60822 129484 152546 130287 42149 67928 47581 62574 49665 44961 174028 156908 57244 180096 49462 14921 38677 3693 44529 75680 104472 192311 140211 71760 192168 32817 136758 184780 99803 135192 57951 120862 4170 197761 124986 137381 125077 161151 142210 170513 168299 182527 144486 61825 7...
result:
ok ok (1 test case)
Test #109:
score: 0
Accepted
time: 228ms
memory: 57588kb
input:
1 100000 551608067 365421420 -487728687 365421420 143644232 365421420 -351527721 365421420 -871435010 958574747 437117589 365421420 79082823 365421420 -932527349 365421420 -51983999 365421420 -981644356 365421420 27516634 365421420 122232864 365421420 -586305842 958574747 -186314882 365421420 -77505...
output:
100000 162875 42651 19838 198386 48279 155849 173542 9938 181614 118364 126069 125721 189391 155499 100945 169379 166030 43565 146217 70473 94354 67266 186530 38856 47344 25515 163591 170627 89297 98655 177029 33464 50576 117280 82600 112516 48457 54917 53428 134847 49585 166102 5627 90421 153194 19...
result:
ok ok (1 test case)
Test #110:
score: 0
Accepted
time: 237ms
memory: 58596kb
input:
1 100000 973177252 740095208 603591199 740095208 912041445 740095208 -879893070 740095208 513021608 740095208 -296817755 397134181 -920132372 740095208 874286779 740095208 -697477339 740095208 675338682 740095208 -688816419 397134181 274927171 397134181 -966544303 740095208 -168526049 740095208 7376...
output:
100000 62522 118733 94330 190315 51274 180232 93290 174744 1779 121085 186284 39306 143390 32936 106739 155774 181729 5590 164420 10055 80684 6450 50455 99786 151814 160855 148610 2208 67297 53411 178163 150463 101249 133198 85465 84744 99474 23276 142723 195972 186429 46945 71819 103691 187487 1531...
result:
ok ok (1 test case)
Test #111:
score: 0
Accepted
time: 239ms
memory: 52200kb
input:
1 100000 801543585 -255560886 -749926618 -255560886 -127843709 -255560886 845588435 -737531782 988339842 -737531782 -626861162 -255560886 918453589 -255560886 749726781 -737531782 -581771893 -386009779 590486060 -386009779 734676998 -737531782 153171830 -737531782 845030651 -737531782 -915274358 -25...
output:
99999 32955 72442 179387 62953 155698 15086 128316 27738 32198 8626 156750 167312 38089 23158 166095 120557 126635 92995 53591 13039 188645 12368 59774 184998 5615 98672 148479 78080 83482 125845 143044 136022 38321 175334 91715 106293 95274 23154 85976 183210 36661 108047 181258 158540 79842 140561...
result:
ok ok (1 test case)
Test #112:
score: 0
Accepted
time: 226ms
memory: 55560kb
input:
1 100000 946325199 -654997315 -893568018 -134419061 729992347 -654997315 759203364 -134419061 931585734 -654997315 813067224 -654997315 -219515258 -654997315 942523112 -654997315 93044508 -654997315 112202638 -654997315 887362429 -654997315 -895695158 -654997315 122895052 -334072657 -236406425 -3340...
output:
99999 122131 105921 119600 129691 32374 196073 130454 86616 110067 38486 2266 133650 140930 81571 85441 108933 53619 6172 103857 113531 91735 94751 110024 48200 76347 186031 178937 107901 82914 60295 23832 116336 35004 51122 8714 10253 135841 75352 104966 36008 139206 33136 84134 14358 134571 164248...
result:
ok ok (1 test case)
Test #113:
score: 0
Accepted
time: 224ms
memory: 58572kb
input:
1 100000 -286313978 229324447 783769798 -259261199 203372724 229324447 903846546 -259261199 -62506027 229324447 -878593732 -259261199 -24614745 229324447 -681646734 -259261199 30846373 229324447 516134098 -259261199 383203441 229324447 -416474256 -259261199 -293604347 -259261199 -122611506 -25926119...
output:
100000 17948 189612 94334 15464 141216 47857 138304 52462 117327 51964 151879 131805 197217 160461 161296 177134 21813 35894 30508 8918 182249 18412 13314 51313 134486 114281 45862 116963 84272 9898 46399 42311 117355 182619 8604 66413 105450 46435 92048 144166 106365 78414 82139 157338 42414 57333 ...
result:
ok ok (1 test case)
Test #114:
score: 0
Accepted
time: 217ms
memory: 48048kb
input:
1 100000 -683388360 919019809 -859428325 -677839811 998213859 512472227 893351203 -331849691 -812365568 378975580 -361448436 -768680818 -498101610 -891785673 -48853924 827302039 -977322158 911487244 630622919 -47675260 464560219 -996571204 781514945 47367981 -641893570 460320130 -716591231 -24159771...
output:
97961 75446 17885 42527 96007 162487 829 95528 80674 25972 78128 164684 32948 62857 65771 182889 158434 61071 158351 12339 93187 146129 180637 14830 4326 55526 146888 193962 13647 17225 82394 192378 131106 103568 167942 44072 25420 127596 51436 42751 66817 42811 156530 183982 138884 152867 2372 1452...
result:
ok ok (1 test case)
Test #115:
score: 0
Accepted
time: 235ms
memory: 58640kb
input:
1 100000 965071155 961909473 965071155 116193246 965071155 -398741995 965071155 -46836400 965071155 107811853 965071155 472916725 965071155 -801103891 965071155 -429946712 965071155 779079739 965071155 -339584185 965071155 -117199737 965071155 -34574080 965071155 940172004 965071155 859809257 965071...
output:
100000 103206 104213 12750 190055 123341 75969 110997 90359 105525 3266 79725 35866 217 144407 88615 129690 102647 169732 108418 185111 155561 21759 186691 112983 120955 46191 137752 100719 140182 143108 10055 117271 91454 71848 151454 51382 176940 12872 188804 104644 104357 85334 84255 86973 155530...
result:
ok ok (1 test case)
Test #116:
score: 0
Accepted
time: 273ms
memory: 54704kb
input:
1 100000 -108646393 572873810 760590825 -20548996 -817355882 -691664274 -652085034 966416413 760590825 -791160497 -684709037 441553262 691698692 281355233 -899208930 128349406 -344513662 428545673 -108646393 7920617 760590825 -153682268 760590825 -5134307 -899208930 891399973 975722593 224997612 760...
output:
100000 77311 196972 137065 181875 22012 81783 179222 37496 167024 17173 140703 89239 102573 27311 70531 135008 169302 3572 58358 162710 73196 155605 170384 151089 693 119828 184959 62373 25529 121455 176254 112449 63448 78390 99014 3266 31887 91245 134001 90298 158929 16918 140542 45086 115549 4869 ...
result:
ok ok (1 test case)
Test #117:
score: 0
Accepted
time: 228ms
memory: 48100kb
input:
1 100000 657771764 499917223 340860304 -894365154 -166481907 95140359 263475661 -453431393 -421208726 -214095000 880473397 -932916417 -75750425 259300793 -605153080 -141604420 562225805 7170053 -611074444 -745330023 834249871 -314820890 608021155 -709004755 -214410370 -48571110 643218522 497384980 3...
output:
96041 197124 35091 180235 22791 14056 179905 171558 116870 120501 18130 58572 174953 157631 68862 34391 30308 183799 22606 30538 176913 138876 127450 73980 107853 182551 192801 101801 193023 147708 196841 4874 10517 163457 52274 11352 103457 43454 110164 77385 50845 22352 104489 48634 60728 159989 9...
result:
ok ok (1 test case)
Test #118:
score: 0
Accepted
time: 216ms
memory: 48036kb
input:
1 100000 -367654468 -952563688 285936870 592116431 -274071733 455847465 -171624585 354239799 349408391 -485168327 767563471 234441392 -528077539 -342651670 502696003 -903892090 -229679854 -452018526 -553390072 218410940 632717195 56077406 588095737 -173132122 -618084086 465397930 931640280 533044102...
output:
80396 15917 175350 54836 16616 183011 92896 55522 130628 71674 133924 188853 152715 83178 65251 2517 198530 151705 173687 126232 50136 56001 120611 748 178496 156402 110677 15250 138613 98160 102437 7919 125916 1413 19436 67777 104265 146646 69216 80445 130739 133587 100466 545 174036 17894 189871 1...
result:
ok ok (1 test case)
Test #119:
score: 0
Accepted
time: 204ms
memory: 47952kb
input:
1 100000 -906200254 -265351581 -61657317 -473114865 952191838 -484210630 -968862768 -688100917 -946086398 207717766 96200317 881558228 645408728 -29904463 -65219541 512094883 -105610142 -944887267 232013995 -248237040 571558060 -90454204 -56844375 -803257756 703491466 211175053 910638201 896424741 -...
output:
48783 27439 81840 87595 66331 198304 136032 128285 131324 127914 1521 123093 9315 144887 7510 153578 194257 175612 89697 52332 57245 165950 114622 108591 65599 79414 76723 188830 141082 114706 103998 133163 11180 63827 29595 159627 17436 5380 92304 198005 132343 179093 10596 298 28778 11955 96832 19...
result:
ok ok (1 test case)
Test #120:
score: 0
Accepted
time: 201ms
memory: 48036kb
input:
1 100000 766382075 -21012642 -128826313 -161927840 507846892 -465151202 -122637205 252503287 673961711 322092096 472140704 525292475 -591417285 438455480 -659982761 -855470959 781169250 -760438229 -230659843 -352619932 64397555 -344061705 249444096 -515285207 -966136666 474387926 836585434 673332290...
output:
9778 135298 186990 2771 64189 177544 172378 89825 76035 67460 106686 118600 64509 52744 43557 81686 2637 179675 167421 74332 146467 42702 22016 56235 70242 163694 179858 176189 177354 87807 145478 5266 103682 156502 75682 168412 67787 172524 105765 134213 151813 97483 124674 92297 117888 71071 76904...
result:
ok ok (1 test case)
Test #121:
score: 0
Accepted
time: 246ms
memory: 78916kb
input:
1 100000 -391309465 574501656 -601163643 398769165 437998755 -432176181 -504670744 400573721 363523163 -727677520 -810716783 387537161 -171290820 222526143 -710458455 -569456596 -546226838 -832409181 531132193 824799149 -523158870 -960204834 907379792 -31354498 -659185380 651124824 -917386965 958360...
output:
100000 183892 195790 27082 63878 146815 107188 107048 116271 189824 169593 9829 165792 5732 157033 147920 66468 167050 50712 27685 110782 140458 155023 127122 193740 150497 54147 40161 152641 119955 23861 14591 93786 108885 195116 178487 52179 1565 198156 144301 132842 177067 164692 41874 105469 121...
result:
ok ok (1 test case)
Test #122:
score: 0
Accepted
time: 226ms
memory: 69904kb
input:
1 100000 -570308074 564028419 41974764 951482748 -458707143 821043169 792070901 519849419 -897928950 732129807 -377209691 238697917 846996677 789967440 92894202 -75895048 674835179 -287863905 818656679 -759156926 -929937983 329230903 52584650 -174966413 -245982588 55776587 619716488 -142539574 -3331...
output:
100000 2177 16275 68107 2980 132379 122096 150542 136435 31066 61391 107293 114168 21829 175947 192557 38918 2628 166076 27493 149815 184140 48762 154214 180999 91714 174989 168306 110306 88178 37693 75021 132212 17692 171520 199183 187073 179631 188006 78733 81683 117394 133877 28220 61841 17157 22...
result:
ok ok (1 test case)
Test #123:
score: 0
Accepted
time: 255ms
memory: 87940kb
input:
1 100000 -870867990 -427477336 377455239 817489100 878782331 -17678742 638141193 -507332664 760969286 -686215018 680187812 -958635909 650765571 -244064336 -162743943 -197718056 -803668177 -612150607 245627960 16037985 -301270470 -415814129 -725795982 901008722 -795739083 25301151 -690989959 99318401...
output:
100000 146907 37288 138708 82149 98980 87605 186288 41383 192407 107345 159127 190484 43394 197814 187784 1785 155206 64049 8574 33349 170298 57031 38887 4639 124591 65336 109434 65390 182667 25960 137089 64562 103349 82249 8677 82983 134620 118347 97057 16805 173270 47518 69609 173045 77436 173849 ...
result:
ok ok (1 test case)
Test #124:
score: 0
Accepted
time: 264ms
memory: 78248kb
input:
1 100000 -539465148 -845708233 41183593 -459286909 -334098911 241729240 -391831038 -16693053 973020777 536265241 556557281 -789431898 52149811 -685715732 -792343215 686258394 464507471 -40092028 -870155969 590469644 465578389 -589697394 -161523675 -991602821 855948608 265525154 -839351205 -62602192 ...
output:
100000 30896 19317 83241 34267 88764 105589 109871 108219 110943 114236 176858 35229 57622 31219 147114 71199 137411 30424 82427 9092 176224 36988 190180 101903 126944 196370 130854 122614 134156 192866 6789 12534 66081 176022 156417 189111 85947 161065 66013 35720 175766 92512 122567 52768 116331 1...
result:
ok ok (1 test case)
Test #125:
score: 0
Accepted
time: 252ms
memory: 77664kb
input:
1 100000 -301707541 -107785349 651696377 527237688 -311820441 -207092527 -214569234 -975358436 701909387 -785968490 -711653988 396775134 320035803 -913625682 593258459 -175337068 238164130 72714700 -539135317 -424645474 -205072058 507538329 -942822743 848584924 20017998 840987059 -272745279 -7423224...
output:
100000 197338 50128 159737 41280 183686 156259 27044 101115 122212 170391 198575 102000 22273 132102 48719 124018 189725 142062 83038 3712 3545 111844 59391 158622 191272 8679 107765 54224 64416 124433 83978 102398 77788 111997 99843 140264 83308 148980 75847 17359 11816 47063 18 162472 78250 178541...
result:
ok ok (1 test case)
Test #126:
score: 0
Accepted
time: 232ms
memory: 73740kb
input:
1 100000 372101953 621089677 -107763756 -662571441 -63243920 659729647 441606222 -20964438 -861658828 -775998558 970349344 -718761240 -11091310 -651405801 723558495 57067049 -334677637 723258287 833883610 54943079 734085988 -274788427 668836759 -415187691 -227285405 23994731 212507360 -328156423 940...
output:
100000 60120 169261 86702 149557 153358 30841 120682 149200 191088 185034 160296 145857 52481 3611 147006 16754 15003 70313 65250 197170 77320 671 151070 66632 46395 185836 135743 113829 137731 108821 58083 131764 177880 84303 28874 172323 188751 105855 37403 185789 31823 81445 174717 128728 57082 1...
result:
ok ok (1 test case)
Test #127:
score: 0
Accepted
time: 224ms
memory: 62632kb
input:
1 100000 -915867003 -471353976 -388104681 -614331870 712512068 -176609228 -249834836 -559087269 653127892 -445584953 754204027 962058868 -859865327 -430551978 -748113746 22447905 -53970847 230698214 488889725 -10963115 856013500 103474622 -985497526 -436330311 596095986 -945139677 35717532 -85633518...
output:
99946 125819 94759 125923 12745 112703 105229 110092 184691 39013 2473 59215 32783 144494 35969 138450 38671 109534 65977 194428 186086 99312 67989 108953 145580 128587 81285 120059 309 130763 80304 199936 143857 120007 22079 45642 47907 90164 147956 170835 146595 196330 154877 144146 184620 8845 15...
result:
ok ok (1 test case)
Test #128:
score: 0
Accepted
time: 248ms
memory: 73416kb
input:
1 100000 -462294685 526220805 -608793181 78935812 -652123710 -88897518 -549445127 -950121976 404063639 -731462283 873109908 911227253 280108661 -384023678 -224512922 -527391217 -606653749 460705189 -795453552 954412985 557042734 419950356 71945893 766707128 975265143 857240778 678089771 850488211 86...
output:
100000 182735 50430 164261 1546 103355 58091 96021 45748 154955 109508 32685 148226 183908 188448 77005 4820 11143 106213 163689 188143 24351 99757 89777 30878 90177 156713 120532 97587 148948 156792 54701 83948 12382 107713 141856 71223 32579 195045 24991 59346 185374 85800 56320 54958 119819 17075...
result:
ok ok (1 test case)
Test #129:
score: 0
Accepted
time: 263ms
memory: 78204kb
input:
1 100000 -217244737 -919036017 839515854 811349301 -529200839 -607492236 206068906 -756100661 -93942296 718088556 164065404 687609627 -335010106 575687136 -753768524 797665484 528969092 -675985219 -833864420 -976856005 -254998531 102163056 193138802 -109129538 -963610238 68206037 -505611099 66224247...
output:
100000 167754 66231 114551 32072 154341 61046 128219 150829 191723 86085 125893 99883 43726 164071 26253 65258 114928 17062 94247 100260 80877 194737 108677 177962 23062 72170 71353 84203 82184 178268 178613 70907 174534 179194 112395 4213 134913 68733 98093 147699 171799 39148 181663 61605 28717 46...
result:
ok ok (1 test case)
Test #130:
score: 0
Accepted
time: 217ms
memory: 48028kb
input:
1 100000 546952831 -551916540 -222366580 -190550190 690748205 621971537 -304787213 -426869636 430677306 737609007 -552529934 -587069496 534035388 -224937134 817092293 51151294 -603326277 963652497 675552100 -708035960 570918080 -54876116 -969756137 789057618 412261743 152512971 404319641 37207120 -1...
output:
95853 186804 137651 169193 78384 40845 180878 145077 109583 128799 181897 8946 144702 83594 139331 111718 112731 163841 28151 2760 101559 94549 20410 125338 45139 7384 170017 168582 129797 57128 195301 35964 12892 185098 93423 4433 117593 44186 44849 197961 148936 126966 21044 63400 56519 129387 982...
result:
ok ok (1 test case)
Test #131:
score: 0
Accepted
time: 258ms
memory: 73564kb
input:
1 100000 -718650142 -337515990 219225987 -796448041 945735467 769273424 -265106195 -836296134 286397419 -465897164 -217444051 -861702365 -142203839 354946276 962047833 625331802 -436237082 697041665 -210015414 251812388 -580562900 -862577184 468877853 314574614 -848683471 -115639376 358203437 674429...
output:
100000 107708 86769 104606 57065 184760 100297 67789 73275 127752 81968 124000 51367 17721 107571 46756 3051 183734 55102 145008 45928 84368 164128 66247 181367 183980 94193 192439 163684 31191 3351 17107 59960 124261 162344 48598 159168 169631 10754 80596 15786 73515 10725 72449 194643 119935 32290...
result:
ok ok (1 test case)
Test #132:
score: 0
Accepted
time: 199ms
memory: 48020kb
input:
1 100000 514065105 703173790 -898391374 199118883 -736313276 118966780 722733109 744001421 495427092 -308368925 -315318854 128815246 269153707 551867497 -795428350 -627563242 -221111684 -748945403 149671640 991495820 -169151249 -133790110 -552570804 601719573 -805801829 -857404452 -491986921 9945430...
output:
35570 85241 119994 107102 194426 52918 178096 107074 38506 25387 95797 11040 78305 129777 139425 103335 135660 130429 116580 48364 29581 178701 142797 102519 29267 19997 143611 173654 12272 140135 59945 99954 98746 8635 130278 28624 34061 81802 100973 120007 29535 40870 139204 55736 104203 79595 567...
result:
ok ok (1 test case)
Test #133:
score: 0
Accepted
time: 267ms
memory: 57708kb
input:
1 100000 -352442278 -740018096 -88202974 -740018096 -738618658 -144110914 -738618658 -604922659 -738618658 -932820553 356311978 -740018096 578254098 -740018096 -738618658 -853474506 366314668 -740018096 -738618658 -328885215 -738618658 804967834 -738618658 -326990482 -675958519 -740018096 -943725244...
output:
100000 21414 93603 46637 83476 141681 161877 20268 143757 40095 73597 171961 56772 86747 30266 101666 197217 17280 119712 127614 115647 75139 182214 62843 191750 95664 176606 113412 176406 166870 23678 120765 188537 120847 111126 176107 151965 105962 639 15794 109917 6847 73819 129468 73462 14803 37...
result:
ok ok (1 test case)
Test #134:
score: 0
Accepted
time: 261ms
memory: 57688kb
input:
1 100000 325122130 172466804 325122130 812054805 325122130 982296227 325122130 -588934091 325122130 -19140359 325122130 547947686 325122130 -958881583 325122130 -115703499 399672789 821857835 -751884489 821857835 -407471339 821857835 -440355675 821857835 -930981956 821857835 325122130 411759969 9942...
output:
100000 17787 110012 188796 50752 139370 80872 45291 168283 199843 141959 137433 13218 178038 61619 131886 5638 96885 89200 106769 153108 90542 3066 108838 136910 180296 88928 87098 61050 172652 171652 50894 104115 129330 74462 174549 35231 165059 103193 88629 97936 47686 162760 123611 170989 150678 ...
result:
ok ok (1 test case)
Test #135:
score: 0
Accepted
time: 245ms
memory: 57456kb
input:
1 100000 -226465324 -765160112 -804076207 -66372335 -996256652 -66372335 -232309074 -66372335 433736878 -66372335 -226465324 884802247 241435841 -66372335 -216832241 -66372335 311207842 -66372335 -226465324 -209742435 368069229 -66372335 -605974269 -66372335 -846600651 -66372335 781736433 -66372335 ...
output:
100000 126717 137610 12054 108926 26692 12256 140702 182169 123509 28800 187744 89439 160507 198216 24183 145190 98736 80072 159402 91885 68162 56771 149056 47334 153978 185127 113697 27631 52652 190567 118677 87866 13470 150495 132865 44080 22227 61872 103597 169440 94202 141130 185656 28896 137692...
result:
ok ok (1 test case)
Test #136:
score: 0
Accepted
time: 251ms
memory: 57780kb
input:
1 100000 -938307807 -589622988 -781309279 862497436 -938307807 -280855161 -938307807 821787178 -938307807 -143785330 -342339007 862497436 -159228282 862497436 480181280 862497436 -725384126 862497436 -780856436 862497436 -915347010 862497436 -292109291 862497436 -183345034 862497436 158697996 862497...
output:
100000 79422 80437 45108 133100 123499 189995 119206 142664 163146 137128 145149 51863 98153 5808 35791 64276 48844 73485 29162 35795 29851 193163 6016 156705 77138 17022 20280 189731 14002 100062 69430 65193 147997 72306 155574 78493 179042 126628 185113 198867 70695 42523 161261 186356 29855 68319...
result:
ok ok (1 test case)
Test #137:
score: 0
Accepted
time: 8ms
memory: 3524kb
input:
10000 1 1 1 1 0 1 1 0 1 1 1 1 1 0 1 1 0 0 1 0 1 1 0 0 0 1 1 1 0 1 1 1 1 0 1 1 1 0 0 1 1 1 1 0 0 1 0 1 0 0 1 0 0 0 1 1 0 1 1 1 1 0 0 1 0 1 1 0 0 1 1 1 0 0 1 1 1 1 0 1 1 0 0 1 1 1 1 1 0 0 1 1 0 1 1 1 1 1 0 0 1 1 1 1 0 1 0 0 1 0 1 1 0 0 0 1 1 1 0 0 1 0 1 1 1 1 1 0 0 1 1 1 0 0 1 1 1 1 0 0 1 0 1 0 0 1 1 ...
output:
1 2 1 1 1 2 1 1 2 1 2 1 1 1 2 1 1 2 1 1 2 0 1 2 0 1 2 1 2 1 1 1 2 1 2 1 1 2 1 0 1 2 0 1 2 1 1 2 0 1 2 0 1 2 1 1 2 0 1 2 1 2 1 1 2 1 1 1 2 0 1 2 1 2 1 0 1 2 0 1 2 0 1 2 1 2 1 0 1 2 1 1 2 0 1 2 0 1 2 0 1 2 1 1 2 1 2 1 0 1 2 0 1 2 1 2 1 1 2 1 1 2 1 1 1 2 0 1 2 1 2 1 1 1 2 0 1 2 1 2 1 1 2 1 1 2 1 0 1 2 ...
result:
ok ok (10000 test cases)
Test #138:
score: 0
Accepted
time: 19ms
memory: 3580kb
input:
10000 1 0 0 1 0 4 1 0 0 2 2 1 1 3 2 0 2 2 0 3 1 2 1 1 0 1 1 2 1 2 3 3 3 1 2 3 2 1 2 2 1 0 2 0 1 2 0 0 1 1 1 0 0 1 5 2 0 2 3 3 0 3 2 0 3 0 0 1 1 3 3 1 0 0 2 1 0 1 1 1 1 0 0 0 1 4 5 2 0 4 1 4 0 0 5 3 4 3 0 3 0 5 3 1 4 4 3 1 2 4 0 1 0 0 4 1 1 0 0 1 1 1 0 0 0 3 3 2 0 1 1 0 3 3 2 2 2 3 2 1 1 0 2 0 0 0 1 ...
output:
1 2 1 4 3 6 5 1 7 4 8 2 1 1 2 1 3 2 1 4 2 2 4 1 3 2 4 2 3 1 5 7 9 10 4 3 8 5 2 1 6 1 2 1 1 1 2 4 1 5 6 7 3 2 4 8 3 2 4 5 3 1 6 0 1 2 1 1 2 2 6 4 1 5 2 3 2 1 4 3 2 4 8 1 6 2 7 5 4 3 1 2 1 1 1 2 1 2 1 2 4 1 3 2 5 12 5 10 3 11 1 2 7 8 6 4 9 3 2 1 6 7 4 3 5 8 0 1 2 1 1 2 2 1 4 3 2 3 4 6 7 2 8 1 3 5 4 9 ...
result:
ok ok (10000 test cases)
Test #139:
score: 0
Accepted
time: 31ms
memory: 3588kb
input:
10000 1 0 1 1 0 4 3 0 2 1 3 1 2 4 4 0 1 3 1 2 4 4 1 0 0 0 1 1 0 1 1 0 3 3 5 2 5 5 3 4 2 0 4 5 5 2 1 2 2 1 1 1 2 2 1 1 1 0 1 2 1 0 1 2 2 0 2 2 1 0 1 0 0 3 1 1 0 1 2 2 2 0 0 0 2 1 1 1 0 0 0 2 0 1 2 0 2 1 0 2 4 3 3 6 4 4 3 7 1 2 4 5 1 6 7 6 5 1 1 0 0 1 2 1 3 3 2 0 1 2 3 3 3 2 1 2 2 2 0 0 2 3 3 0 1 0 0 ...
output:
0 1 2 4 7 6 4 8 5 1 3 2 1 1 2 0 1 2 2 3 6 1 2 4 5 2 1 4 2 3 1 1 2 2 2 4 3 1 1 2 1 3 1 2 6 3 4 5 1 1 2 2 2 3 1 4 4 8 7 2 5 3 1 4 6 0 1 2 1 4 1 2 3 3 5 3 2 1 6 4 1 1 2 1 1 4 2 3 2 6 2 5 4 1 3 3 9 4 1 5 6 8 2 3 7 10 1 1 2 2 1 2 3 4 0 1 2 1 2 1 0 1 2 1 1 2 6 7 2 5 3 10 8 6 1 12 9 4 11 2 1 2 4 3 4 7 4 1 ...
result:
ok ok (10000 test cases)
Test #140:
score: 0
Accepted
time: 47ms
memory: 3856kb
input:
10000 1 1 1 0 1 4 0 1 1 1 2 1 0 2 2 0 0 0 1 2 2 2 4 3 2 1 0 1 3 0 3 2 3 2 2 2 0 3 3 5 6 4 2 0 2 7 1 7 0 9 7 2 1 9 8 4 9 8 0 6 6 3 3 0 3 0 4 1 1 4 0 2 2 5 4 1 3 4 3 4 2 3 0 2 4 2 0 1 1 1 0 0 1 0 1 0 1 0 0 5 3 4 4 1 0 7 0 2 1 4 2 7 2 6 4 3 6 5 6 2 10 5 3 6 4 0 2 8 7 4 4 3 3 7 0 7 5 4 5 7 3 5 0 6 0 0 1...
output:
1 1 2 4 4 8 7 2 1 3 5 6 4 8 1 6 5 7 2 3 4 4 2 3 4 7 10 5 8 1 6 9 6 4 8 7 3 12 6 10 9 5 11 1 2 2 1 2 4 3 1 2 1 5 9 10 7 6 4 3 1 5 2 8 10 19 12 20 2 5 9 4 18 14 16 8 7 6 10 1 11 15 13 3 17 1 4 3 1 2 1 1 2 2 4 3 1 2 0 1 2 2 4 3 1 2 4 2 3 7 4 1 6 8 5 7 9 6 1 7 5 11 10 2 14 12 8 4 3 13 2 4 2 1 3 8 8 5 14...
result:
ok ok (10000 test cases)
Test #141:
score: 0
Accepted
time: 45ms
memory: 3612kb
input:
10000 2 2 3 2 2 3 1 0 3 5 1 5 5 5 1 2 4 4 5 3 6 1 2 2 0 6 3 0 3 6 3 0 1 0 2 1 0 0 0 2 0 2 2 1 1 1 0 0 4 1 2 2 4 2 0 3 4 4 2 0 1 0 2 0 4 5 1 3 0 1 3 2 2 0 0 2 1 0 0 3 0 0 3 3 1 1 6 2 4 5 5 2 3 0 4 6 0 2 1 2 2 0 0 5 1 6 2 5 4 6 4 4 2 2 0 1 2 0 1 2 0 0 1 1 2 1 1 0 4 4 3 6 2 6 0 7 4 1 0 2 5 5 1 6 7 12 1...
output:
1 2 1 3 4 3 9 10 7 3 5 2 1 4 6 8 3 2 6 3 5 4 1 0 1 2 4 1 5 3 2 4 8 6 7 5 2 10 5 3 9 7 1 6 4 8 6 4 1 12 11 2 9 6 3 7 10 5 8 4 4 1 3 7 2 6 8 5 2 2 8 3 5 1 4 6 7 10 7 20 9 24 4 17 2 3 21 6 22 19 5 10 14 18 23 11 13 16 1 8 12 15 5 2 5 9 3 6 8 4 7 10 1 0 1 2 3 1 6 5 2 3 4 6 2 3 1 11 5 7 10 12 4 8 9 6 3 4...
result:
ok ok (10000 test cases)
Test #142:
score: 0
Accepted
time: 64ms
memory: 3756kb
input:
10000 10 1 0 0 1 1 4 1 2 2 1 0 4 0 3 4 4 1 3 3 0 4 3 3 3 2 0 0 2 3 1 4 1 0 0 4 2 2 4 1 1 7 1 3 5 6 4 0 5 3 1 5 6 3 0 2 1 1 2 1 6 4 3 1 3 6 3 3 4 2 12 5 0 1 5 9 5 3 8 9 2 4 7 1 1 0 6 8 6 9 3 7 5 7 9 4 3 2 8 7 6 6 9 1 8 4 8 9 0 7 8 5 4 2 6 5 3 6 3 8 7 5 2 7 1 6 6 6 2 4 0 7 3 2 2 0 1 2 7 7 2 6 0 6 5 4 ...
output:
10 14 4 10 15 12 7 9 11 18 16 8 6 3 19 13 5 2 20 1 17 6 3 14 12 2 10 6 4 1 13 11 9 8 5 7 12 6 18 5 10 3 19 1 21 13 23 24 16 12 15 20 11 7 2 17 4 14 22 9 8 8 16 13 4 15 1 10 6 2 5 11 8 14 7 9 3 12 2 2 3 6 5 1 4 2 3 2 4 1 2 3 2 4 1 16 15 31 5 19 29 7 30 28 11 4 21 16 20 24 35 9 26 36 27 1 22 6 17 13 2...
result:
ok ok (10000 test cases)
Test #143:
score: 0
Accepted
time: 75ms
memory: 3924kb
input:
10000 1 0 1 1 1 3 1 2 2 2 0 2 0 0 1 1 0 1 2 1 0 0 0 0 1 1 1 6 3 2 3 0 1 3 2 0 4 3 3 1 0 4 0 1 3 3 3 4 4 1 4 4 5 2 3 6 6 6 4 4 0 6 3 7 3 1 3 3 4 4 5 6 7 3 1 1 2 3 1 3 0 0 2 1 0 3 6 5 2 2 5 4 7 1 5 5 3 2 4 4 0 6 5 6 4 8 5 1 4 6 0 1 1 0 1 1 6 4 11 3 7 9 10 0 5 1 10 4 4 7 8 8 2 4 0 7 0 1 3 4 2 4 0 6 6 2...
output:
1 2 1 3 2 3 1 5 4 6 2 3 4 1 2 6 4 2 7 10 12 11 3 5 1 9 6 8 5 8 3 2 10 1 5 6 7 4 9 3 2 5 1 3 4 6 6 3 7 12 9 8 10 4 2 6 11 1 5 1 1 2 4 3 5 7 10 8 12 9 6 1 2 4 11 4 4 6 5 2 8 1 3 7 5 4 10 9 3 7 12 11 8 1 5 2 6 1 2 1 16 17 11 30 4 2 13 26 6 27 32 23 20 19 8 16 14 5 21 31 22 24 9 10 28 1 3 29 7 18 15 12 ...
result:
ok ok (10000 test cases)
Test #144:
score: 0
Accepted
time: 86ms
memory: 3956kb
input:
10000 12 13 12 11 3 11 1 7 0 9 8 11 6 2 17 1 9 8 11 17 0 11 11 6 17 15 11 9 5 13 2 0 3 5 3 12 9 5 6 0 16 3 8 17 11 17 6 7 6 7 7 7 2 5 10 4 7 4 2 7 1 1 7 1 8 3 2 2 6 8 4 6 6 2 8 10 10 9 9 9 1 10 11 10 8 7 1 0 3 0 8 6 1 12 3 2 7 3 2 8 6 8 3 3 0 3 3 5 5 10 0 0 7 6 6 3 2 1 3 3 4 0 2 0 2 2 1 1 1 0 0 1 1 ...
output:
11 3 2 6 11 9 13 22 23 10 4 24 19 17 16 18 8 12 7 14 5 15 1 20 21 6 14 3 10 12 9 2 5 1 4 7 8 13 6 11 8 6 3 2 16 13 10 4 1 7 18 11 12 14 8 9 17 5 15 2 3 4 5 1 2 6 0 1 2 1 1 2 3 3 4 6 1 2 5 2 4 2 3 1 1 1 2 7 7 11 10 9 8 1 6 14 2 12 4 3 13 5 15 16 19 38 35 37 7 26 12 18 20 23 31 40 9 29 27 11 17 28 10 ...
result:
ok ok (10000 test cases)
Test #145:
score: 0
Accepted
time: 92ms
memory: 3808kb
input:
10000 2 0 0 1 1 0 1 1 0 12 1 1 3 3 6 1 4 3 0 2 5 0 0 5 5 4 2 6 2 3 2 1 0 3 2 2 0 6 1 2 5 5 3 0 4 0 5 1 2 0 4 1 1 3 5 2 1 5 16 5 2 3 2 7 5 7 10 1 2 9 6 5 1 10 5 6 7 5 5 8 3 6 2 6 4 2 0 8 7 3 10 9 1 5 7 3 8 3 6 8 9 0 3 4 3 1 10 7 8 8 0 3 1 7 6 10 8 3 3 0 10 1 5 15 5 5 2 1 2 3 6 3 2 5 6 6 0 6 5 1 6 1 5...
output:
2 3 2 4 1 12 18 21 4 12 22 10 2 17 7 24 8 16 19 23 6 20 14 9 13 11 3 1 15 5 16 17 6 20 28 8 29 19 25 31 24 16 4 3 10 32 5 14 26 21 11 15 18 13 9 12 2 1 7 27 30 23 22 15 17 16 24 7 26 20 29 6 9 4 13 23 28 18 5 1 8 10 21 25 12 22 15 27 14 11 19 2 3 30 21 2 38 27 20 11 36 32 6 3 16 7 39 10 37 23 17 1 4...
result:
ok ok (10000 test cases)
Test #146:
score: 0
Accepted
time: 108ms
memory: 4036kb
input:
10000 8 7 4 14 3 1 8 9 12 2 7 7 1 12 3 5 3 7 12 1 9 7 2 9 10 4 12 6 8 12 12 11 2 6 4 3 1 1 2 2 4 0 0 0 3 0 2 3 1 0 0 1 4 2 3 3 2 1 56 0 5 10 15 5 0 6 17 5 3 11 14 3 5 5 12 7 2 0 14 13 18 14 9 9 6 13 15 7 18 19 13 11 6 7 9 16 12 8 0 20 18 20 0 19 9 5 16 19 14 2 20 3 11 11 13 10 0 5 1 3 19 15 7 17 19 ...
output:
7 14 3 16 11 6 1 12 4 8 2 7 15 9 13 5 10 6 6 11 7 1 4 10 3 12 9 2 8 5 56 38 112 31 33 93 46 32 53 85 102 10 104 63 6 83 87 25 76 60 23 16 50 91 107 49 28 79 17 77 37 20 98 12 106 101 75 8 19 94 80 89 24 40 72 84 90 64 34 26 59 22 36 39 21 48 15 70 11 99 14 82 2 29 109 111 62 58 35 105 52 1 78 7 44 6...
result:
ok ok (10000 test cases)
Test #147:
score: 0
Accepted
time: 110ms
memory: 4180kb
input:
1000 116 40 14 11 4 18 3 11 36 20 21 11 5 10 21 8 37 8 38 11 22 40 33 4 4 2 36 31 21 0 0 37 16 21 39 16 42 41 9 13 25 6 41 33 2 38 30 30 38 9 33 19 24 0 20 7 38 27 21 22 39 1 41 42 18 3 1 5 40 38 18 38 32 4 29 1 19 0 27 16 36 22 31 11 29 30 41 42 31 34 8 16 19 1 24 27 9 13 19 1 9 8 18 34 24 9 4 22 3...
output:
116 168 180 110 200 210 191 59 25 62 144 11 155 31 21 43 65 99 89 57 5 229 73 82 228 58 67 32 171 44 185 217 220 34 77 222 201 91 151 147 116 164 211 18 76 102 13 4 161 109 40 182 206 121 166 17 132 130 30 54 178 148 125 41 94 189 192 84 61 56 215 159 124 119 117 86 157 149 70 126 163 213 194 69 114...
result:
ok ok (1000 test cases)
Test #148:
score: 0
Accepted
time: 125ms
memory: 6944kb
input:
100 1751 676 962 2080 1171 2449 361 678 1915 276 2074 1308 739 1328 739 442 105 1452 14 962 26 614 2079 1882 1674 1619 868 1354 435 2075 2473 514 1497 2365 2044 601 734 2227 1499 218 519 1848 600 219 1462 207 450 1644 1089 2157 2364 1890 1306 697 1851 1293 1484 1068 1656 2405 2194 625 727 2460 375 2...
output:
1627 1040 508 1546 1662 1681 399 1810 3098 2511 2314 798 1849 1463 809 1160 3485 3252 2031 1213 1992 394 2659 48 599 3414 542 2006 127 1868 2185 3244 2205 1727 3111 2444 3339 1514 1252 192 3099 447 2968 1592 2773 2281 2832 1230 2871 439 430 676 1070 2215 1259 232 2103 1431 130 294 461 2708 3486 2731...
result:
ok ok (100 test cases)
Test #149:
score: 0
Accepted
time: 156ms
memory: 14956kb
input:
10 5923 990 3340 465 3601 4722 4502 1946 1225 2051 4441 3447 2001 1373 1646 4604 1645 2067 2525 2984 486 1779 2132 281 2392 3682 3334 2807 2874 1709 1458 3249 1263 3358 1826 1067 3769 1473 3101 144 1498 2492 553 341 1852 397 4263 4683 3010 4547 4068 2198 689 2087 4032 182 545 3578 3282 3051 2356 258...
output:
5878 20 9532 9296 8034 9883 759 1476 124 3882 9797 4292 1883 5765 3760 1121 8147 9493 9685 3001 55 8735 4964 6640 241 4685 6497 665 799 10463 2792 2285 6198 3288 8823 7562 10183 8713 2233 4011 2105 369 3428 9156 4266 82 240 2467 7465 8622 3355 3742 4174 8301 333 11366 1927 4931 11284 3177 8908 7314 ...
result:
ok ok (10 test cases)
Test #150:
score: 0
Accepted
time: 223ms
memory: 51188kb
input:
1 100000 167013 125784 135343 32228 31636 139579 125392 28117 109132 130552 18863 126456 70093 140399 65187 131293 60990 127651 2030 57656 111845 109917 114136 18890 12132 33233 93847 20459 44854 159309 21435 47947 118357 48471 33129 78641 154624 169493 106664 83316 164632 49121 5045 149642 161002 1...
output:
86849 171913 140427 59593 123958 101644 102762 73941 61233 146350 110514 37092 144410 156672 171061 83372 55103 82937 44365 89524 76081 114767 184208 142760 16278 190175 69482 124733 103119 181507 126660 99523 166736 43453 31840 159152 69100 144643 19595 6068 161352 187150 115718 186635 174041 19336...
result:
ok ok (1 test case)
Test #151:
score: 0
Accepted
time: 107ms
memory: 3708kb
input:
10000 8 2 1 0 1 2 3 3 3 2 0 1 0 1 3 3 1 1 2 0 2 2 2 0 3 1 1 3 2 0 0 3 0 6 2 3 3 0 0 1 2 1 0 3 3 3 2 2 1 1 0 0 1 0 0 2 1 2 56 2 4 5 2 6 6 4 9 5 1 8 5 10 7 8 3 2 0 8 6 6 1 0 4 9 8 10 10 2 2 3 10 6 3 0 9 8 4 2 5 4 5 10 2 1 8 8 8 10 3 2 6 6 10 1 0 2 3 6 0 2 10 8 2 9 9 6 7 6 4 3 9 6 9 9 3 5 10 5 0 10 6 9...
output:
8 12 7 3 4 16 8 14 10 9 11 5 1 2 13 6 15 6 11 12 2 6 5 1 7 4 3 8 10 9 56 60 95 31 16 44 39 27 78 107 14 67 62 22 25 80 41 7 105 91 18 65 47 36 4 37 87 102 33 90 55 85 38 68 82 42 96 13 110 23 75 111 99 86 100 109 24 64 32 8 19 6 10 45 94 58 52 101 34 92 73 83 49 112 57 74 72 104 26 89 77 106 3 30 11...
result:
ok ok (10000 test cases)
Test #152:
score: 0
Accepted
time: 113ms
memory: 4204kb
input:
1000 116 8 8 4 15 0 7 0 0 9 4 14 3 12 9 8 9 9 2 3 13 7 6 7 8 7 5 14 10 6 14 3 12 15 14 6 11 14 2 4 5 3 10 5 14 0 10 13 8 14 1 3 1 14 5 0 13 1 7 2 12 12 7 15 1 13 14 4 13 2 15 4 10 9 9 3 0 14 12 10 12 12 12 10 13 11 3 10 11 11 9 2 11 13 7 12 6 5 12 1 9 7 15 11 8 0 14 4 0 13 6 14 9 2 6 1 13 7 12 12 10...
output:
116 119 133 35 2 100 164 51 96 78 214 76 102 162 88 230 32 130 182 74 212 77 186 145 97 180 124 17 53 204 67 115 131 22 15 229 85 220 148 73 174 33 113 173 25 19 6 176 27 175 110 147 56 14 66 39 80 28 58 156 10 34 82 104 92 213 42 101 222 209 215 181 86 153 48 31 75 7 60 41 194 68 30 16 49 206 59 64...
result:
ok ok (1000 test cases)
Test #153:
score: 0
Accepted
time: 126ms
memory: 6348kb
input:
100 1751 43 55 50 32 40 59 17 23 14 41 50 44 52 57 26 29 6 21 2 50 46 36 34 9 44 12 55 22 20 5 23 45 50 43 53 6 41 58 19 27 22 53 16 32 11 56 7 36 20 39 23 48 46 48 9 51 15 4 40 38 51 36 21 45 52 7 49 37 10 24 16 56 33 50 48 56 51 34 11 33 43 18 20 59 4 9 41 44 52 23 26 26 20 51 40 36 37 59 40 56 37...
output:
1751 2735 2645 1610 539 233 2675 3387 3331 1520 929 901 2660 1754 699 93 2137 822 2369 2446 1301 42 947 1298 1697 1349 329 3407 819 869 1996 1657 997 2384 1600 49 3398 2946 3 2164 300 3020 472 1840 2475 2027 1558 1971 3443 410 1097 2219 229 804 2373 972 1678 580 1646 2365 1655 3305 825 2623 2574 137...
result:
ok ok (100 test cases)
Test #154:
score: 0
Accepted
time: 172ms
memory: 17340kb
input:
10 5923 53 27 26 66 1 35 65 99 6 99 28 12 61 5 106 43 37 67 106 91 84 102 76 52 10 52 20 74 11 12 29 4 42 71 86 53 42 37 89 37 70 36 12 19 78 53 8 15 106 11 28 97 10 11 100 89 55 2 46 94 82 43 57 84 62 101 65 58 16 16 82 59 91 76 7 30 50 65 107 9 46 12 105 55 11 10 97 23 83 82 6 50 52 57 69 53 77 83...
output:
5923 8670 5609 5757 4788 7669 10677 3351 5034 11403 9720 9993 10312 10795 1595 4257 7264 10803 10672 5276 4964 11168 2419 6521 5333 5798 10037 10394 4442 8550 4654 10421 11619 6820 9306 4014 8843 8902 4404 1745 11692 3264 5357 1468 8079 10444 11565 7422 2886 8381 138 6749 6630 8166 9733 1602 7363 18...
result:
ok ok (10 test cases)
Test #155:
score: 0
Accepted
time: 284ms
memory: 69124kb
input:
1 100000 436 393 386 68 30 357 47 276 18 61 414 156 347 273 304 106 72 167 114 83 260 443 192 432 324 196 388 313 153 350 284 316 165 408 26 313 298 348 293 221 318 119 380 345 27 325 91 223 403 186 374 185 416 143 418 325 217 7 147 209 385 220 128 207 58 331 35 309 151 313 284 372 335 384 181 274 3...
output:
100000 32225 177036 199975 163767 41208 13395 139161 195610 34051 137689 168856 143487 163583 137681 153544 163727 159887 86432 199902 112136 126675 124210 129962 138153 145109 180571 88950 7196 185219 170443 137592 80488 105965 142104 33257 101189 39330 62186 183497 192792 146751 43336 65346 50526 ...
result:
ok ok (1 test case)