QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#235773#7569. LineskkioAC ✓84ms127064kbC++1714.1kb2023-11-03 08:58:232023-11-03 08:58:23

Judging History

你现在查看的是最新测评结果

  • [2023-11-03 08:58:23]
  • 评测
  • 测评结果:AC
  • 用时:84ms
  • 内存:127064kb
  • [2023-11-03 08:58:23]
  • 提交

answer

#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,avx2")
#pragma GCC optimize("Ofast","unroll-loops","inline","no-stack-protector")
#include <bits/stdc++.h>
using namespace std;
namespace Def{
    #define fir first
    #define sec second
    #define lson (tr[i].ls)
    #define rson (tr[i].rs)
    #define FIO(file) freopen(file".in","r",stdin), freopen(file".out","w",stdout)
    #define Untie() ios::sync_with_stdio(0), cin.tie(0),cout.tie(0)
    typedef long long ll;
    typedef double db;
    typedef long double ldb;
    typedef unsigned int uint;
    typedef unsigned long long ull;
    typedef pair<int,int> pii;
    typedef pair<ll,ll> pll;
    typedef __int128_t i128;
}
using namespace Def;
namespace FastIO {
	struct IO {
	    char ibuf[(1 << 20) + 1], *iS, *iT, obuf[(1 << 20) + 1], *oS;
	    IO() : iS(ibuf), iT(ibuf), oS(obuf) {} ~IO() { fwrite(obuf, 1, oS - obuf, stdout); }
		#if ONLINE_JUDGE
		#define gh() (iS == iT ? iT = (iS = ibuf) + fread(ibuf, 1, (1 << 20) + 1, stdin), (iS == iT ? EOF : *iS++) : *iS++)
		#else
		#define gh() getchar()
		#endif
		inline bool eof (const char &ch) { return ch == ' ' || ch == '\n' || ch == '\r' || ch == 't' || ch == EOF; }
	    inline long long read() {
	        char ch = gh();
	        long long x = 0;
	        bool t = 0;
	        while (ch < '0' || ch > '9') t |= ch == '-', ch = gh();
	        while (ch >= '0' && ch <= '9') x = (x << 1) + (x << 3) + (ch ^ 48), ch = gh();
	        return t ? ~(x - 1) : x;
	    }
	    inline void read (char *s) {
	    	char ch = gh(); int l = 0;
	    	while (eof(ch)) ch = gh();
	    	while (!eof(ch)) s[l++] = ch, ch = gh();
	    }
	    inline void read (double &x) {
	    	char ch = gh(); bool t = 0;
	    	while (ch < '0' || ch > '9') t |= ch == '-', ch = gh();
	    	while (ch >= '0' && ch <= '9') x = x * 10 + (ch ^ 48), ch = gh();
	    	if (ch != '.') return t && (x = -x), void(); ch = gh();
	    	for (double cf = 0.1; '0' <= ch && ch <= '9'; ch = gh(), cf *= 0.1) x += cf * (ch ^ 48);
	    	t && (x = -x);
	    }
	    inline void pc (char ch) {
	    	#ifdef ONLINE_JUDGE
	    	if (oS == obuf + (1 << 20) + 1) fwrite(obuf, 1, oS - obuf, stdout), oS = obuf; 
	    	*oS++ = ch;
	    	#else
	    	putchar(ch);
	    	#endif
		}
        inline void write (char *s)
        {
            int len = strlen(s);
            for(int i = 0; i < len; i++)pc(s[i]);
        }
		template<typename _Tp>
	    inline void write (_Tp x) {
	    	static char stk[64], *tp = stk;
	    	if (x < 0) x = ~(x - 1), pc('-');
			do *tp++ = x % 10, x /= 10;
			while (x);
			while (tp != stk) pc((*--tp) | 48);
	    }
	    inline void puts(const char *s){
			int len = strlen(s);
			for (int i = 0; i < len; i++)pc(s[i]);
		}
	} io;
	inline long long read () { return io.read(); }
	template<typename Tp>
	inline void read (Tp &x) { io.read(x); }
	template<typename _Tp>
	inline void write (_Tp x) { io.write(x); }
}
using namespace FastIO;
namespace misc{
    constexpr int infi=1e9;
    constexpr int minfi=0x3f3f3f3f;
    constexpr ll infl=1e18;
    constexpr ll minfl=0x3f3f3f3f3f3f3f3f;
    constexpr int mod=998244353;
    constexpr int inv2=(mod+1)/2;
    constexpr int inv3=(mod+1)/3;
    mt19937_64 rnd(0x3494393);
    template<typename T,typename E>
        inline T ksm(T b,E p){T ret=1;while(p){if(p&1)ret=1ll*ret*b%mod;b=1ll*b*b%mod;p>>=1;}return ret;}
    template<typename T,typename E> 
        inline T ginv(T v){return ksm(v,mod-2);}
    template<typename T,typename E>
        inline void cmax(T &a,E b){a<b?(a=b,1):0;}
    template<typename T,typename E>
        inline void cmin(T &a,E b){a>b?(a=b,1):0;}
    template<typename T,typename E>
        inline void cadd(T &a,E b){(a+=b)>=mod?(a-=mod):0;}
    template<typename T,typename E>
        inline void csub(T &a,E b){(a-=b)<0?(a+=mod):0;}
    template<typename T,typename E>
        inline void cmul(T &a,E b){a=1ll*a*b%mod;}
    template<typename T,typename E>
        inline T madd(T a,E b){return (a+=b)>=mod?(a-mod):a;}
    template<typename T,typename E>
        inline T msub(T a,E b){return (a-=b)<0?(a+mod):a;}
    template<typename T,typename E>
        inline T mmul(T a,E b){return 1ll*a*b%mod;}
    template<typename T>
        struct dseg{T *first,*last;dseg(T* _l,T* _r):first(_l),last(_r){}};
    inline void debug(void){cerr<<'\n';}
    template<typename T,typename... arg>
        inline void debug(T x,arg... r){cerr<<x<<' ';debug(r...);}
    template<typename T,typename... arg>
        inline void debug(dseg<T> A,arg... v){cerr<<"[ ";for(T* i=A.first;i!=A.last;++i)cerr<<*i<<' ';cerr<<"] ";debug(v...);}
    template<typename T>
        inline T randseg(T l,T r){assert(l<=r);return rnd()%(r-l+1)+l;}
    template<typename T>
        inline bool gbit(T v,int bit){return v>>bit&1;}
    inline ll gcd(ll a,ll b){if(!b||!a) return a+b;ll az=__builtin_ctz(a),bz=__builtin_ctz(b),z=(az>bz)?bz:az,t;b>>=bz;while(a) a>>=az,t=a-b,az=__builtin_ctz(t),b=a<b?a:b,a=t<0?-t:t;return b<<z;}
    inline ll exgcd(ll a,ll b,ll &x,ll &y){if(!b){x=1,y=0;return a;}ll g=exgcd(b,a%b,y,x);y-=x*(a/b);return g;}
    inline ll Sum1(ll n){return n*(n+1)/2;}
    inline ll Sum2(ll n){return n*(n+1)*(2*n+1)/6;}
    inline ll Sqr(ll n){return n*n;}
    #define binom(n,m) (n<0||m<0||n<m?0:1ll*fac[n]*ifac[m]%mod*ifac[n-m]%mod)
    #define likely(x) (__builtin_expect(!!(x),1))
    #define unlikely(x) (__builtin_expect(!!(x),0))
}
using namespace misc;
#include <bits/stdc++.h>
using namespace std;

const double eps = 1e-8;
int sgn(double x) {
    if (fabs(x) < eps) {
        return 0;
    }
    return (x < 0) ? -1 : 1;
}

struct Point {
    double x, y;
    Point(double x = 0.0, double y = 0.0) : x(x), y(y) {}
};
typedef Point Vector;
const double pi = acos(-1.0);

Point operator - (Point A) {
    return Point(-A.x,-A.y); 
}
Vector operator + (Vector A, Vector B) {
    return Vector(A.x + B.x, A.y + B.y);
}
Vector operator - (Point A, Point B) {
    return Vector(A.x - B.x, A.y - B.y);
}
Vector operator * (Vector A, double p) {
    return Vector(A.x * p, A.y * p);
}
Vector operator / (Vector A, double p) {
    return Vector(A.x / p, A.y / p);
}
bool operator < (const Point A, const Point B) {
    return A.x < B.x || (sgn(A.x - B.x) == 0 && A.y < B.y);
}
bool operator == (const Point A, const Point B) {
    return sgn(A.x - B.x) == 0 && sgn(A.y - B.y) == 0;
}
double dot(Vector A, Vector B) {
    return A.x * B.x + A.y * B.y;
}
double cross(Vector A, Vector B) {
    return A.x * B.y - A.y * B.x;
}
double length(Vector A) {
    return sqrt(dot(A, A));
}
double length(Point A,Point B){
    return length(length(A-B));
}
double angle(Vector A, Vector B) {
    return acos(dot(A, B) / length(A) / length(B));
}
double areatri(Point A, Point B, Point C) {
    return fabs(cross(B - A, C - A)) / 2;
}
Vector rotate(Vector A, double rad) {
    return Vector(A.x * cos(rad) - A.y * sin(rad), A.x * sin(rad) + A.y * cos(rad));
}
Vector normal(Vector A) {
    double L = length(A);
    return Vector(-A.y / L, A.x / L);
}
Point lineintersection(Point P, Vector v, Point Q, Vector w) {
    Vector u = P - Q;
    double t = cross(w, u) / cross(v, w);
    return P + v * t;
}
double linedistance(Point P, Point A, Point B) {
    Vector v1 = B - A, v2 = P - A;
    return fabs(cross(v1, v2)) / length(v1);
}
Point lineproject(Point P, Point A, Point B) {
    Vector v = B - A;
    return A + v * (dot(v, P - A) / dot(v, v));
}
double segdistance(Point P, Point A, Point B) {
    if (sgn(dot(P - A, B - A)) < 0) {
        return length(P - A);
    }
    if (sgn(dot(P - B, A - B)) < 0) {
        return length(P - B);
    }
    return fabs(cross(B - A, P - A)) / length(A - B);
}
bool segintersection(Point A, Point B, Point P, Point Q) {
    double c1 = cross(B - A, P - A), c2 = cross(B - A, Q - A);
    double c3 = cross(Q - P, A - P), c4 = cross(Q - P, B - P);
    return sgn(c1) * sgn(c2) < 0 && sgn(c3) * sgn(c4) < 0;
}
bool onseg(Point P, Point A, Point B) {
    return sgn(cross(A - P, B - P)) == 0 && sgn(dot(A - P, B - P)) < 0;
}
struct Circle {
    Point O;
    double r;
    Circle(Point O, double r): O(O), r(r) {}
    Point point(double a) {
        return Point(O.x + cos(a) * r, O.y + sin(a) * r);
    }
};
int linecirintersection(Circle C, Point A, Point B, vector<Point>& sol) {
    double a = (B.x - A.x) * (B.x - A.x) + (B.y - A.y) * (B.y - A.y);
    double b = 2 * (B.x - A.x) * (A.x - C.O.x) + 2 * (B.y - A.y) * (A.y - C.O.y);
    double c = (A.x - C.O.x) * (A.x - C.O.x) + (A.y - C.O.y) * (A.y - C.O.y) - C.r * C.r;
    double delta = b * b - 4 * a * c;
    if (sgn(delta) < 0) {
        return 0;
    }
    if (sgn(delta) == 0) {
        double t = -b / (2 * a);
        sol.push_back(A + (B - A) * t);
        return 1;
    }
    double t1 = (-b - sqrt(delta)) / (2 * a);
    double t2 = (-b + sqrt(delta)) / (2 * a);
    sol.push_back(A + (B - A) * t1);
    sol.push_back(A + (B - A) * t2);
    return 2;
}
double vecangle(Vector v) {
    return atan2(v.y, v.x);
}
int circirintersection(Circle C1, Circle C2, vector<Point>& sol) {
    double d = length(C1.O - C2.O);
    if (sgn(fabs(C1.r - C2.r) - d) > 0) {
        return 0;
    }
    if (sgn(C1.r + C2.r - d) < 0) {
        return 0;
    }
    double a = vecangle(C2.O - C1.O);
    double da = acos((C1.r * C1.r + d * d - C2.r * C2.r) / (2 * C1.r * d));
    if (sgn(da) == 0) {
        sol.push_back(C1.point(a));
        return 1;
    }
    sol.push_back(C1.point(a - da));
    sol.push_back(C1.point(a + da));
    return 2;
}
int gettans(Point P, Circle C, vector<Vector>& v) {
    Vector u = C.O - P;
    double d = length(u);
    if (sgn(d - C.r) < 0) {
        return 0;
    }
    if (sgn(d - C.r) == 0) {
        v.push_back(rotate(u, pi / 2));
        return 1;
    }
    double ang = asin(C.r / d);
    v.push_back(rotate(u, -ang));
    v.push_back(rotate(u, ang));
    return 2;
}
int getcirtans(Circle C1, Circle C2, vector<Point>& v1, vector<Point>& v2) {
    if (C1.r < C2.r) {
        swap(C1, C2);
        swap(v1, v2);
    }
    double d = length(C1.O - C2.O);
    double rd = C1.r - C2.r;
    double rsum = C1.r + C2.r;
    if (sgn(d - rd) < 0) {
        return 0;
    }
    if (sgn(d) == 0 && sgn(C1.r - C2.r) == 0) {
        return -1;
    }
    double base = vecangle(C2.O - C1.O);
    if (sgn(d - rd) == 0) {
        v1.push_back(C1.point(base));
        v2.push_back(C2.point(base));
        return 1;
    }
    double ang = acos(rd / d);
    v1.push_back(C1.point(base + ang));
    v2.push_back(C2.point(base + ang));
    v1.push_back(C1.point(base - ang));
    v2.push_back(C2.point(base - ang));
    if (sgn(d - rsum) < 0) {
        return 2;
    }
    if (sgn(d - rsum) == 0) {
        v1.push_back(C1.point(base));
        v2.push_back(C2.point(pi + base));
        return 3;
    }
    ang = acos(rsum / d);
    v1.push_back(C1.point(base + ang));
    v2.push_back(C2.point(pi + base + ang));
    v1.push_back(C1.point(base - ang));
    v2.push_back(C2.point(pi + base - ang));
    return 4;
}
double polygonarea(Point *p, int n) {
    double area = 0;
    for (int i = 1; i <= n - 1; i++) {
        area += cross(p[i] - p[1], p[i + 1] - p[1]);
    }
    return area / 2;
}
int inpoly(Point p, Point *Poly, int n) {
    int wn = 0;
    for (int i = 1; i <= n; i++) {
        if (onseg(p, Poly[i], Poly[(i + 1) % n])) return -1;
        int k = sgn(cross(Poly[(i + 1) % n] - Poly[i], p - Poly[i]));
        int d1 = sgn(Poly[i].y - p.y);
        int d2 = sgn(Poly[(i + 1) % n].y - p.y);
        if (k > 0 && d1 <= 0 && d2 > 0)  wn++;
        if (k < 0 && d2 <= 0 && d1 > 1)  wn--;
    }
    if (wn != 0) return 1;
    return 0;
}
int convexhull(Point *p, int n, Point *Poly) {
    sort(p + 1, p + n + 1);
    int m = 0;
    for (int i = 1; i <= n; i++) {
        while (m > 1 && cross(Poly[m] - Poly[m - 1], p[i] - Poly[m - 1]) >= 0) m--;
        Poly[++m] = p[i];
    }
    return m;
}
double hulldiam(Point *p, int n){
    double ans=0;
    p[n+1]=p[1];
    for(int i=1,j=2;i<n;i++)
    {
        while(j<=n&&areatri(p[i],p[i+1],p[j])<areatri(p[i],p[i+1],p[j+1]))j=j%n+1;
        ans=max(ans,length(p[i],p[j]));
        ans=max(ans,length(p[i+1],p[j]));
    }
    return ans;
}
bool anglecmp(Point a,Point b)
{return cross(a,b)!=0?cross(a,b)>0:length(a)<length(b);}
void anglesort(Point *a,int n)
{
    if(n==0)return;
    sort(a+1,a+1+n);
    for(int i=2;i<=n;i++)a[i]=a[i]-a[1];
    sort(a+2,a+1+n,anglecmp);
    for(int i=2;i<=n;i++)a[i]=a[i]+a[1];
}
int Minkovski(Point *a,int n,Point *b,int m,Point *c)
{
    // for(int i=1;i<=n;i++)debug(a[i].x,a[i].y);
    // for(int i=1;i<=m;i++)debug(b[i].x,b[i].y);
    int r=0;
    if(n==0)
    {for(int i=1;i<=m;i++)c[i]=b[i];r=m;return m;}
    if(m==0)
    {for(int i=1;i<=n;i++)c[i]=a[i];r=n;return n;}
    int i=1,j=1;
    while(i<=n&&j<=m)
    {
        //debug(i,j);
        c[++r]=a[i]+b[j];
        if(i==n&&j==m)break;
        if(i<n&&(j==m||cross(a[i+1]-a[i],b[j+1]-b[j])<0))i++;
        else if(i<n&&j<m&&cross(a[i+1]-a[i],b[j+1]-b[j])==0)i++,j++;
        else j++;
    }
    //for(int i=1;i<=r;i++)debug("!",c[i].x,c[i].y);
    return r;
}
const int maxn=1e6+10;
int n,a[maxn],b[maxn],c[maxn],tot;
Point A[maxn],B[maxn],C[maxn],ta[maxn],tb[maxn],tc[maxn],res[maxn];
int lena,lenb,lenc;
bool vis[maxn];
int main(){
    n=read();
    for(int i=0;i<=n;i++)a[i]=read(),ta[i+1]={i,a[i]};
    for(int i=0;i<=n;i++)b[i]=read(),tb[i+1]={i,b[i]};
    for(int i=0;i<=n;i++)c[i]=read(),tc[i+1]={i,c[i]};
    lena=convexhull(ta,n+1,A);
    lenb=convexhull(tb,n+1,B);
    lenc=convexhull(tc,n+1,C);
    tot=Minkovski(A,lena,B,lenb,res);
    lena=Minkovski(res,tot,C,lenc,A);
    //for(int i=1;i<=lena;i++)
    //    debug(A[i].x,A[i].y);
    //sort(A+1,A+1+lena,[&](Point a,Point b){return a.y<b.y;});
    for(int i=1;i<=lena;i++){
        vis[(int)A[i].x]=1;
    }
    vector<int> ans;
    for(int i=0;i<=3*n;i++)if(!vis[i])ans.push_back(i);
    write((int)ans.size()),io.pc('\n');
    for(int v:ans)
        write(v),io.pc(' ');
}
/*
3
3 1 8 7
9 1 3 1
5 1 1 6
*/

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 116248kb

input:

3
3 1 8 7
9 1 3 1
5 1 1 6

output:

5
1 3 4 7 8 

result:

ok 6 numbers

Test #2:

score: 0
Accepted
time: 16ms
memory: 115632kb

input:

1
1 2
1 2
1 2

output:

2
1 2 

result:

ok 3 number(s): "2 1 2"

Test #3:

score: 0
Accepted
time: 11ms
memory: 115876kb

input:

252
336470888 634074578 642802746 740396295 773386884 579721198 396628655 503722503 971207868 202647942 2087506 268792718 46761498 443917727 16843338 125908043 691952768 717268783 787375312 150414369 693319712 519096230 45277106 856168102 762263554 674936674 407246545 274667941 279198849 527268921 1...

output:

733
4 5 7 9 10 11 12 14 16 17 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 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 102 103 104 105 106 10...

result:

ok 734 numbers

Test #4:

score: 0
Accepted
time: 8ms
memory: 115704kb

input:

96
75475634 804928248 476927808 284875072 503158867 627937890 322595515 786026685 645468307 669240390 939887597 588586447 973764525 521365644 710156469 985188306 860350786 11308832 784695957 770562147 208427221 35937909 67590963 726478310 475357775 255361535 135993561 166967811 46718075 851555000 70...

output:

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

result:

ok 273 numbers

Test #5:

score: 0
Accepted
time: 4ms
memory: 116000kb

input:

237
374288891 535590429 751244358 124321145 232930851 266089174 543529670 773363571 319728747 580543238 582720391 468188689 490702144 598813561 138628383 284660056 733781508 155605777 931759705 245485733 723534730 257812292 794937524 596788519 188451996 981010588 14483682 59267682 959461493 32106527...

output:

685
2 5 6 7 8 9 10 11 12 13 14 15 17 18 19 20 21 22 23 24 26 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 44 45 46 47 48 49 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 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 102 103 104 106 107 108 ...

result:

ok 686 numbers

Test #6:

score: 0
Accepted
time: 51ms
memory: 121584kb

input:

213081
673102149 561219907 730593611 814024114 812959730 314305867 469496529 350635050 699021890 342102981 815487777 787982418 857896659 526518374 421876106 438907614 902179526 449645826 783856158 865633510 238642240 774653971 962475573 467098727 196513513 561435449 333165290 951567552 726980720 645...

output:

639188
3 6 7 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 10...

result:

ok 639189 numbers

Test #7:

score: 0
Accepted
time: 8ms
memory: 116428kb

input:

221
412106895 291882089 564718673 358502890 837699009 657489855 690430685 632939232 373282330 398630021 753287868 667584659 79866982 603966291 850348020 738379364 480642952 593942770 930919906 485781288 903492853 141752547 984789430 897217447 909607734 846893014 211655411 843867422 789467242 4098289...

output:

644
1 3 5 6 7 9 10 11 12 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 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 102 103 104 105...

result:

ok 645 numbers

Test #8:

score: 0
Accepted
time: 24ms
memory: 116484kb

input:

270
5887448 757703054 544067926 902981667 712695184 295641139 911364840 620276118 902318577 865222469 250896470 987378388 742028793 681414208 133595743 597659626 649040970 33207011 223207847 960704874 418600362 658594226 417168695 767527655 622701955 867509363 235369723 31134588 702210660 439147697 ...

output:

785
3 5 7 9 10 11 12 14 15 17 18 19 20 21 22 23 25 26 27 28 29 30 31 33 34 35 36 37 38 39 40 41 42 43 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 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 102 103 104 105 106 107 108 ...

result:

ok 786 numbers

Test #9:

score: 0
Accepted
time: 8ms
memory: 115768kb

input:

422
449924898 783332532 378192988 592684636 147499872 343857831 837331700 197547597 576579017 776525316 188696560 12204822 669031820 758862125 826908873 897131377 817438988 737312468 370271596 580852652 638740575 585501313 439482552 637837864 335796176 447934224 259084035 778210267 469729886 9086579...

output:

1238
3 4 5 7 8 9 10 11 12 13 15 16 17 18 20 21 22 23 24 25 26 27 29 30 31 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 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 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 100 101 102 103 104 105 106 107 10...

result:

ok 1239 numbers

Test #10:

score: 0
Accepted
time: 15ms
memory: 115504kb

input:

63
43705451 513994713 652509537 432130709 317463343 687041819 58265855 479851779 250839457 538085060 126496650 186774359 331193631 836310042 255380788 756411639 690869710 176576709 222368048 906033133 8623893 807375696 461796409 362923880 194114590 733391789 137574156 670510137 237249112 673135534 5...

output:

170
2 3 4 8 9 10 11 12 13 14 15 16 17 19 20 21 22 23 25 26 27 28 29 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 47 48 49 50 51 52 53 54 55 56 57 58 59 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 102 103 104 105 106 107 108...

result:

ok 171 numbers

Test #11:

score: 0
Accepted
time: 7ms
memory: 115580kb

input:

407
782710197 539624191 631858791 976609486 752268030 30225807 279200011 467188665 630132600 594612100 769329445 916633496 258196658 913757959 538628510 55883389 859267729 615840950 514655989 526180911 523731402 324217375 189142970 643299496 907208811 754008138 161288468 562810007 149992530 99742161...

output:

1194
2 3 5 6 7 8 9 10 11 12 13 14 15 16 18 19 20 21 22 23 24 25 27 28 29 30 31 32 33 34 35 37 38 39 40 41 42 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 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 102 103 104 105 10...

result:

ok 1195 numbers

Test #12:

score: 0
Accepted
time: 16ms
memory: 116796kb

input:

18
640274071 983359971 71550121 96204862 799843967 446173607 796619138 402690754 223219513 668171337 312183499 905549873 673542337 566661387 879397647 434495917 631413076 150918417 579868000
224422012 126195703 525305826 535526356 404334728 653535984 998133227 879226371 59632864 356493387 62611196 8...

output:

36
2 4 5 6 8 10 11 13 15 16 17 18 20 21 22 23 24 25 26 27 28 30 31 33 34 35 37 38 39 40 41 42 43 46 47 48 

result:

ok 37 numbers

Test #13:

score: 0
Accepted
time: 12ms
memory: 116544kb

input:

171
379278816 8989449 50899375 935650934 529615950 494390299 427618702 979962232 602512657 429731081 544950885 930376306 895512660 644109304 162645369 439000371 504843798 590182657 726931749 139537086 346335916 42147505 262872917 129420744 661597501 578558088 462749196 951932734 269236805 532121466 ...

output:

492
2 3 5 7 8 9 10 12 13 14 15 16 17 19 20 21 23 24 25 26 27 28 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 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 102 103 104 105 106 1...

result:

ok 493 numbers

Test #14:

score: 0
Accepted
time: 15ms
memory: 115508kb

input:

311
678092074 34618927 179991732 480129711 404612126 132541583 648552857 967299118 276773097 341033928 482750975 104945843 262707175 721557221 591117284 593247929 673241816 734479602 19219689 759684863 156410721 264021888 990219478 999730953 374691722 304207141 781430804 139199900 741788735 85640754...

output:

912
1 3 4 5 6 7 8 10 11 12 13 14 15 16 17 19 20 21 22 23 24 25 26 27 28 29 30 31 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 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 92 93 94 95 96 97 98 99 100 101 102 103 104 105 ...

result:

ok 913 numbers

Test #15:

score: 0
Accepted
time: 4ms
memory: 116952kb

input:

155
417096820 205472596 159340986 464799976 839416813 475725571 869487013 249603301 246000832 807626376 125583769 129772276 484677498 799005138 284430414 892719679 841639834 28519651 871316142 234608449 526294039 926087759 157757527 575073865 87785943 884632001 659920924 326467067 804275257 32591781...

output:

438
3 5 6 7 10 11 12 13 14 15 17 18 20 22 23 24 25 26 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 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 81 82 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 101 102 103 104 105 106 107 108 109 110...

result:

ok 439 numbers

Test #16:

score: 0
Accepted
time: 8ms
memory: 116600kb

input:

204
715910077 936134778 138690239 714311457 9380284 523942263 795453872 826874779 625293976 864153416 63383860 9374518 851872013 171420351 567678137 46967238 715070557 172816596 18379890 854756227 41401548 147962143 180071384 5192585 800880165 610281054 978602533 73542745 717018675 650203893 4693378...

output:

590
4 5 6 7 8 9 10 12 13 14 15 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 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 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 102 103 104 105 10...

result:

ok 591 numbers

Test #17:

score: 0
Accepted
time: 16ms
memory: 115272kb

input:

344
454914823 961764255 972815301 258790234 444184972 162093547 16388028 814211665 299554415 625713159 1183950 34200951 73842336 394092460 996150051 906247500 588501279 612080836 165443639 179936708 556509057 664803822 907417945 875502793 513974386 190705915 562125357 965842615 484537901 119714164 8...

output:

1012
2 4 5 8 9 10 11 12 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 32 33 34 35 36 37 38 39 40 41 42 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 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 102 103 104 105 106...

result:

ok 1013 numbers

Test #18:

score: 0
Accepted
time: 0ms
memory: 115452kb

input:

188
48695377 692426437 952164554 243460498 173956955 210310239 237322183 96515847 678847559 682240199 498792552 208770488 736004147 176573082 279397774 910751954 756899297 611153589 457731579 654860294 71616567 886678205 929731802 745813002 227068607 476163480 585839669 153109781 252057127 738967538...

output:

537
4 5 6 7 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 29 30 31 33 34 35 36 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 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 95 96 97 98 99 100 101 102 103 104 105 106 107...

result:

ok 538 numbers

Test #19:

score: 0
Accepted
time: 15ms
memory: 115324kb

input:

137
347508634 863280107 226481104 787939275 48953130 553494227 458256339 673787326 353107999 298575751 436592642 233596921 957974470 254020999 707869688 64999512 630330019 755450534 309828032 275008072 736467180 403519884 952045659 321155914 235130124 201812533 759297086 45409652 164800546 913510512...

output:

391
2 4 5 6 7 8 9 10 11 12 13 15 16 17 18 19 20 21 22 23 24 26 28 29 30 31 32 33 34 35 36 37 38 39 40 42 43 44 45 46 47 48 49 50 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 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 103 104 105 106 107 10...

result:

ok 392 numbers

Test #20:

score: 0
Accepted
time: 65ms
memory: 122628kb

input:

273481
86513380 593942288 60606166 627385348 778725113 896678215 384223198 661124212 882144246 60135494 374392733 408166459 179944793 331468916 401182818 69503967 798728037 899747479 456891780 895155850 251574689 770618459 679392220 46241930 948224345 77204690 488044102 937709522 227287068 237796591...

output:

820389
3 4 5 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 43 44 45 46 47 48 49 50 51 52 53 54 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 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 10...

result:

ok 820390 numbers

Test #21:

score: 0
Accepted
time: 7ms
memory: 115812kb

input:

30
680293934 914539062 744988123 317088317 653721289 239862203 605157354 943428394 261437390 821695238 312192823 432992892 547139308 408916833 829654733 223751525 672158759 193787527 749179721 665046731 471714903 992492843 406738781 916552138 661318566 362662255 806725710 830009392 140030486 2274157...

output:

74
1 4 7 8 9 10 11 12 13 14 16 17 18 19 20 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 39 40 41 42 43 44 45 46 47 48 49 50 51 53 54 55 56 57 58 59 60 61 63 64 65 66 67 68 69 70 71 72 74 75 77 78 79 80 81 83 85 86 89 

result:

ok 75 numbers

Test #22:

score: 0
Accepted
time: 11ms
memory: 116532kb

input:

204
509061481 552472140 16115810 148658854 66743034 628305150 677780684 519361360 208050516 401554301 954478790 346543678 387546138 832279893 641889899 80960260 717802881 588066499 661699500 83254572 759454419 427833657 255743179 199661234 694729965 875591136 862937826 103626886 473906880 203664913 ...

output:

595
2 4 5 6 7 8 9 10 11 12 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 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 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 102 103 104 1...

result:

ok 596 numbers

Test #23:

score: 0
Accepted
time: 8ms
memory: 116292kb

input:

48
807874739 723325809 995465063 693137631 646771913 971489138 603747543 801665542 882310956 163114045 892278880 371370111 459773357 909727810 630170326 940240523 886200899 882106547 953987440 703402350 274561928 794932233 278057036 924747250 407824186 456015997 886652138 290894052 386650298 5279509...

output:

131
1 3 5 6 8 9 10 11 12 13 14 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 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 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 102 103 104 105...

result:

ok 132 numbers

Test #24:

score: 0
Accepted
time: 12ms
memory: 117016kb

input:

393
546879484 748955287 974814317 532583704 671511192 314673126 824681699 789002429 261604100 219641085 389887482 250972352 976710976 987175727 58642240 534679569 759631621 26403492 101051189 178325936 789669437 16806616 5403597 795057458 415885703 36440858 765142258 183193923 154169524 292428558 63...

output:

1157
2 4 5 6 7 8 10 11 12 13 14 15 16 17 18 19 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 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 92 93 94 95 96 97 98 99 100 101 102 103 104 10...

result:

ok 1158 numbers

Test #25:

score: 0
Accepted
time: 12ms
memory: 115392kb

input:

45
845692742 774584765 103906675 222286673 251540072 657857114 45615854 71306611 790640347 835976636 327687572 570766082 48938195 769656348 341889962 393959831 928029640 320443541 248114937 798473713 159552755 533648295 27717454 75433075 128979924 762089911 788856571 930269601 361880239 616714636 33...

output:

122
2 4 5 6 7 8 9 10 11 12 13 15 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 33 34 35 36 37 38 39 40 41 42 43 44 45 46 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 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 95 96 97 98 99 100 101 102 103 104 105 106 10...

result:

ok 123 numbers

Test #26:

score: 0
Accepted
time: 58ms
memory: 121448kb

input:

227185
439473295 505246946 83255928 766765450 981312055 706073806 971582714 648578089 464900787 597536380 265487663 450368323 565875814 847104265 475394581 693431581 241651850 464740486 100211390 418621491 969627560 755522678 50031311 945743283 842074145 342514772 962313987 822569471 129399465 79125...

output:

681503
3 5 6 7 9 10 11 12 13 14 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 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 102 103 104 10...

result:

ok 681504 numbers

Test #27:

score: 0
Accepted
time: 18ms
memory: 115708kb

input:

30
178478041 676100616 622413694 606211522 711084038 344225090 192516869 635914975 139161226 359096124 908320457 770162052 933070329 69776374 758642303 552711844 820115276 609037430 392499330 598577781 484735069 272364358 72345168 670829299 850135662 627972337 691061003 9836638 601951395 115543689 4...

output:

74
3 4 5 6 7 8 9 10 12 13 14 15 16 17 19 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 41 42 43 44 45 46 48 49 50 52 53 54 55 56 57 58 59 60 61 62 64 65 66 67 68 69 70 71 72 73 74 76 77 78 79 81 82 83 85 87 

result:

ok 75 numbers

Test #28:

score: 0
Accepted
time: 47ms
memory: 123096kb

input:

224874
477291299 701730093 601762947 295914491 586080214 392441782 413451025 918219158 813421666 415623163 846120547 649764293 155040653 147224291 892146922 411992106 988513294 903077479 539563079 218725559 999842579 639462933 504724433 541139507 708454075 648588686 864518420 902136508 514694813 880...

output:

674571
4 5 6 7 8 10 11 12 13 14 15 17 18 19 20 21 22 24 25 26 27 28 29 30 31 32 33 35 36 37 38 39 40 41 42 44 45 46 48 49 50 51 52 53 54 55 56 57 58 59 61 62 63 64 65 66 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 1...

result:

ok 674572 numbers

Test #29:

score: 0
Accepted
time: 7ms
memory: 115172kb

input:

219
216296044 432392275 581112201 135360564 20884901 735625770 339417884 495490636 192714810 177182907 783920637 969558023 377010976 224672208 175394644 711463856 156911312 47374424 686626828 133840632 74758600 861337316 527038290 116482420 421548297 934046251 888232732 89403674 282214039 204307334 ...

output:

633
1 2 6 7 9 10 11 12 13 15 17 18 19 20 21 22 23 24 25 27 28 29 30 31 32 33 34 35 36 37 38 39 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 101 102 103 104 105 106 107 ...

result:

ok 634 numbers

Test #30:

score: 0
Accepted
time: 11ms
memory: 115624kb

input:

63
810076598 458021753 710204558 679839341 190848372 373777054 560352039 482827522 866975249 793518459 576496536 849160264 744205491 302120125 458642367 570744118 30342034 486638665 683947472 753988410 589866109 378178995 549352147 841568436 429609814 514471112 911947045 981703545 344700561 37885030...

output:

171
1 3 4 6 7 8 9 11 12 13 14 15 17 18 19 20 21 22 23 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 44 45 46 47 48 49 50 51 52 53 54 55 56 58 59 60 61 62 63 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 102 103 104 105 106 10...

result:

ok 172 numbers

Test #31:

score: 0
Accepted
time: 23ms
memory: 116656kb

input:

11
254114048 188683934 689553812 74575014 920620356 567217938 781286195 765131704 246268393 555078202 514296626 873986697
966175814 84600746 592146985 870215868 198740052 485711417 831011221 933944700 399940915 600053378 276698708 711878644
142704035 240120164 790437165 874003415 257443979 143327875...

output:

23
1 3 5 8 9 10 11 12 13 15 16 17 18 19 20 22 23 24 26 27 28 30 32 

result:

ok 24 numbers

Test #32:

score: 0
Accepted
time: 11ms
memory: 115964kb

input:

94
937657403 561775796 665714203 201112847 478866292 955660885 853909525 195840478 47657327 839969970 861615297 787537483 656839540 802931102 109414855 582200412 244384174 174957684 333465591 647119837 687680431 180618385 125703107 994987740 176115433 607824854 991873472 442588205 31511862 199494439...

output:

266
2 4 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 29 30 31 32 33 35 36 37 38 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 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 102 103 104 105 10...

result:

ok 267 numbers

Test #33:

score: 0
Accepted
time: 79ms
memory: 124140kb

input:

299252
336470888 634074578 642802746 740396295 773386884 579721198 396628655 503722503 971207868 202647942 2087506 268792718 46761498 443917727 16843338 125908043 691952768 717268783 787375312 150414369 693319712 519096230 45277106 856168102 762263554 674936674 407246545 274667941 279198849 52726892...

output:

897726
1 2 4 5 6 7 8 10 11 12 13 14 15 16 17 18 19 20 21 22 23 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 102 ...

result:

ok 897727 numbers

Test #34:

score: 0
Accepted
time: 72ms
memory: 121692kb

input:

248096
75475634 804928248 476927808 284875072 503158867 627937890 322595515 786026685 645468307 669240390 939887597 588586447 973764525 521365644 710156469 985188306 860350786 11308832 784695957 770562147 208427221 35937909 67590963 726478310 475357775 255361535 135993561 166967811 46718075 85155500...

output:

744251
1 2 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 37 38 39 40 41 42 43 44 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 102 1...

result:

ok 744252 numbers

Test #35:

score: 0
Accepted
time: 27ms
memory: 117332kb

input:

64237
374288891 535590429 751244358 124321145 232930851 266089174 543529670 773363571 319728747 580543238 582720391 468188689 490702144 598813561 138628383 284660056 733781508 155605777 931759705 245485733 723534730 257812292 794937524 596788519 188451996 981010588 14483682 59267682 959461493 321065...

output:

192679
1 2 3 4 5 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 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 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 102 1...

result:

ok 192680 numbers

Test #36:

score: 0
Accepted
time: 25ms
memory: 116120kb

input:

13081
673102149 561219907 730593611 814024114 812959730 314305867 469496529 350635050 699021890 342102981 815487777 787982418 857896659 526518374 421876106 438907614 902179526 449645826 783856158 865633510 238642240 774653971 962475573 467098727 196513513 561435449 333165290 951567552 726980720 6453...

output:

39229
1 2 3 4 5 6 7 8 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 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 102...

result:

ok 39230 numbers

Test #37:

score: 0
Accepted
time: 38ms
memory: 120816kb

input:

129221
412106895 291882089 564718673 358502890 837699009 657489855 690430685 632939232 373282330 398630021 753287868 667584659 79866982 603966291 850348020 738379364 480642952 593942770 930919906 485781288 903492853 141752547 984789430 897217447 909607734 846893014 211655411 843867422 789467242 4098...

output:

387638
1 2 3 4 5 6 7 8 9 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 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 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 102...

result:

ok 387639 numbers

Test #38:

score: 0
Accepted
time: 50ms
memory: 121272kb

input:

210770
5887448 757703054 544067926 902981667 712695184 295641139 911364840 620276118 902318577 865222469 250896470 987378388 742028793 681414208 133595743 597659626 649040970 33207011 223207847 960704874 418600362 658594226 417168695 767527655 622701955 867509363 235369723 31134588 702210660 4391476...

output:

632271
1 2 4 5 6 7 8 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 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 102 ...

result:

ok 632272 numbers

Test #39:

score: 0
Accepted
time: 16ms
memory: 116536kb

input:

35422
449924898 783332532 378192988 592684636 147499872 343857831 837331700 197547597 576579017 776525316 188696560 12204822 669031820 758862125 826908873 897131377 817438988 737312468 370271596 580852652 638740575 585501313 439482552 637837864 335796176 447934224 259084035 778210267 469729886 90865...

output:

106234
1 2 4 5 6 7 8 9 10 11 12 13 14 15 16 17 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 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 103 1...

result:

ok 106235 numbers

Test #40:

score: 0
Accepted
time: 55ms
memory: 121264kb

input:

151563
43705451 513994713 652509537 432130709 317463343 687041819 58265855 479851779 250839457 538085060 126496650 186774359 331193631 836310042 255380788 756411639 690869710 176576709 222368048 906033133 8623893 807375696 461796409 362923880 194114590 733391789 137574156 670510137 237249112 6731355...

output:

454666
1 2 4 5 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 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 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 102 103...

result:

ok 454667 numbers

Test #41:

score: 0
Accepted
time: 23ms
memory: 118228kb

input:

100407
782710197 539624191 631858791 976609486 752268030 30225807 279200011 467188665 630132600 594612100 769329445 916633496 258196658 913757959 538628510 55883389 859267729 615840950 514655989 526180911 523731402 324217375 189142970 643299496 907208811 754008138 161288468 562810007 149992530 99742...

output:

301194
1 2 3 4 5 6 7 8 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 88 89 90 91 92 93 94 95 96 97 98 99 100 101 10...

result:

ok 301195 numbers

Test #42:

score: 0
Accepted
time: 40ms
memory: 121044kb

input:

196518
640274071 983359971 71550121 96204862 799843967 446173607 796619138 402690754 223219513 668171337 312183499 905549873 673542337 566661387 879397647 434495917 631413076 150918417 579868000 224422012 126195703 525305826 535526356 404334728 653535984 998133227 879226371 59632864 356493387 626111...

output:

589523
1 2 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 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 589524 numbers

Test #43:

score: 0
Accepted
time: 73ms
memory: 124056kb

input:

300000
481199252 336470888 634074578 642802746 740396295 773386884 579721198 396628655 503722503 971207868 202647942 2087506 268792718 46761498 443917727 16843338 125908043 691952768 717268783 787375312 150414369 693319712 519096230 45277106 856168102 762263554 674936674 407246545 274667941 27919884...

output:

899964
1 2 3 4 5 7 8 9 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 28 29 30 31 32 33 34 35 36 37 38 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 102 1...

result:

ok 899965 numbers

Test #44:

score: 0
Accepted
time: 80ms
memory: 123192kb

input:

300000
54748096 75475634 804928248 476927808 284875072 503158867 627937890 322595515 786026685 645468307 669240390 939887597 588586447 973764525 521365644 710156469 985188306 860350786 11308832 784695957 770562147 208427221 35937909 67590963 726478310 475357775 255361535 135993561 166967811 46718075...

output:

899959
1 2 3 4 5 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 40 41 42 43 44 45 46 47 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 102 1...

result:

ok 899960 numbers

Test #45:

score: 0
Accepted
time: 71ms
memory: 122276kb

input:

300000
923264237 374288891 535590429 751244358 124321145 232930851 266089174 543529670 773363571 319728747 580543238 582720391 468188689 490702144 598813561 138628383 284660056 733781508 155605777 931759705 245485733 723534730 257812292 794937524 596788519 188451996 981010588 14483682 59267682 95946...

output:

899967
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 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 ...

result:

ok 899968 numbers

Test #46:

score: 0
Accepted
time: 52ms
memory: 122680kb

input:

300000
496813081 673102149 561219907 730593611 814024114 812959730 314305867 469496529 350635050 699021890 342102981 815487777 787982418 857896659 526518374 421876106 438907614 902179526 449645826 783856158 865633510 238642240 774653971 962475573 467098727 196513513 561435449 333165290 951567552 726...

output:

899980
1 2 4 5 6 7 8 9 10 11 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 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 102 1...

result:

ok 899981 numbers

Test #47:

score: 0
Accepted
time: 84ms
memory: 122284kb

input:

300000
365329221 412106895 291882089 564718673 358502890 837699009 657489855 690430685 632939232 373282330 398630021 753287868 667584659 79866982 603966291 850348020 738379364 480642952 593942770 930919906 485781288 903492853 141752547 984789430 897217447 909607734 846893014 211655411 843867422 7894...

output:

899965
1 2 3 4 5 6 7 8 9 10 11 12 13 14 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 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 102...

result:

ok 899966 numbers

Test #48:

score: 0
Accepted
time: 71ms
memory: 122356kb

input:

300000
643910770 5887448 757703054 544067926 902981667 712695184 295641139 911364840 620276118 902318577 865222469 250896470 987378388 742028793 681414208 133595743 597659626 649040970 33207011 223207847 960704874 418600362 658594226 417168695 767527655 622701955 867509363 235369723 31134588 7022106...

output:

899965
1 2 3 4 5 6 7 8 9 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 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 102...

result:

ok 899966 numbers

Test #49:

score: 0
Accepted
time: 60ms
memory: 123796kb

input:

300000
72235422 449924898 783332532 378192988 592684636 147499872 343857831 837331700 197547597 576579017 776525316 188696560 12204822 669031820 758862125 826908873 897131377 817438988 737312468 370271596 580852652 638740575 585501313 439482552 637837864 335796176 447934224 259084035 778210267 46972...

output:

899964
1 2 4 5 7 8 9 10 11 12 13 14 15 16 17 18 19 20 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 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 102 103...

result:

ok 899965 numbers

Test #50:

score: 0
Accepted
time: 73ms
memory: 122464kb

input:

300000
940751563 43705451 513994713 652509537 432130709 317463343 687041819 58265855 479851779 250839457 538085060 126496650 186774359 331193631 836310042 255380788 756411639 690869710 176576709 222368048 906033133 8623893 807375696 461796409 362923880 194114590 733391789 137574156 670510137 2372491...

output:

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

result:

ok 899983 numbers

Test #51:

score: 0
Accepted
time: 70ms
memory: 123096kb

input:

300000
514300407 782710197 539624191 631858791 976609486 752268030 30225807 279200011 467188665 630132600 594612100 769329445 916633496 258196658 913757959 538628510 55883389 859267729 615840950 514655989 526180911 523731402 324217375 189142970 643299496 907208811 754008138 161288468 562810007 14999...

output:

899966
1 2 4 5 6 7 8 9 10 11 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 91 92 93 94 95 96 97 98 99 100 101 102 1...

result:

ok 899967 numbers

Test #52:

score: 0
Accepted
time: 59ms
memory: 122788kb

input:

300000
598196518 640274071 983359971 71550121 96204862 799843967 446173607 796619138 402690754 223219513 668171337 312183499 905549873 673542337 566661387 879397647 434495917 631413076 150918417 579868000 224422012 126195703 525305826 535526356 404334728 653535984 998133227 879226371 59632864 356493...

output:

899967
1 2 3 4 5 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 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 899968 numbers

Test #53:

score: 0
Accepted
time: 63ms
memory: 123312kb

input:

300000
912149237 363466377 620626948 150922063 379388246 337989371 546524476 213744663 834088687 132205703 49627076 877197788 762125725 134100202 407490723 873245847 138825265 367231477 388114707 736045459 317603055 504530447 601398019 308750832 655108624 961452210 958860181 79799073 290948672 58895...

output:

899954
1 2 4 5 6 7 8 9 10 11 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 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 92 93 94 95 96 97 98 99 100 101 102 103 105...

result:

ok 899955 numbers

Test #54:

score: 0
Accepted
time: 67ms
memory: 124048kb

input:

300000
90232661 642047925 214407502 176551541 358737500 882468148 126553355 851895947 760055547 414509885 723887515 638757532 404958520 158926635 774685238 950693764 422072988 371735931 261545429 175309700 464666804 124678225 116505528 530625215 677422481 686538226 376987106 510480830 169438792 7119...

output:

899952
3 5 7 8 9 11 12 13 14 15 16 17 18 19 21 22 23 24 25 26 27 28 29 30 31 32 33 34 36 37 38 39 40 41 42 43 44 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 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 ...

result:

ok 899953 numbers

Test #55:

score: 0
Accepted
time: 70ms
memory: 124100kb

input:

300000
973348789 215596769 953412248 907213722 192862561 867138412 856325339 340304127 686022406 696814067 103180659 400317275 342758610 333496172 996655561 733174385 555577606 525983490 429943447 174382452 461987448 599601811 631613037 752499598 844960530 261881138 90081327 90905691 193153105 96349...

output:

899958
3 6 7 8 10 11 12 13 14 15 16 17 19 20 21 22 23 24 25 26 27 28 29 30 31 33 34 35 36 37 38 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 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 102 103 104 105 106...

result:

ok 899959 numbers

Test #56:

score: 0
Accepted
time: 60ms
memory: 122908kb

input:

300000
151432213 938888718 252225505 932843200 172211815 411617189 586097322 388520819 906956562 979118249 632216907 16652827 135334508 358322605 363850076 250813790 543858033 530487944 303374169 613646693 314083901 514716885 441687842 119598173 572307091 132191347 98142845 376363256 366610521 85579...

output:

899955
3 4 5 6 7 8 9 10 11 13 14 15 16 17 18 19 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 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 10...

result:

ok 899956 numbers

Test #57:

score: 0
Accepted
time: 67ms
memory: 122660kb

input:

300000
329515637 512437562 696262955 808729574 446528364 956095966 461093497 26672103 127890717 261422432 306477346 73179867 778167302 532892142 585820399 328261707 827105755 979702798 176804891 757943638 461147649 839897366 516603864 636439853 594620948 857277363 811237066 396979605 95357537 748093...

output:

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

result:

ok 899954 numbers

Test #58:

score: 0
Accepted
time: 71ms
memory: 124144kb

input:

300000
212631765 380953703 290043508 834359051 280653426 940766231 895898185 74888795 53857577 543726614 980737786 834739610 715967393 557718576 807790722 405709624 255577669 838983060 345202909 51983687 753435590 314820952 31711373 858314236 616934805 727587571 524331287 977404466 268814954 7901360...

output:

899941
2 3 6 8 10 11 13 14 16 17 18 19 21 22 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 49 50 51 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 75 76 77 78 79 80 81 82 83 84 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 ...

result:

ok 899942 numbers

Test #59:

score: 0
Accepted
time: 76ms
memory: 122416kb

input:

300000
390715189 659535251 883824062 859988529 260002679 485245008 65861656 418072783 274791732 120998092 654998225 596299354 653767483 732288113 174985237 483157541 538825392 138454811 513600927 196280632 605532042 934968730 546818882 375155915 49314070 302930483 532392804 262862031 292529266 68243...

output:

899945
3 4 6 7 9 10 11 12 13 15 16 18 19 20 21 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 42 43 44 45 46 47 48 49 50 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 70 71 72 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 1...

result:

ok 899946 numbers

Test #60:

score: 0
Accepted
time: 60ms
memory: 127064kb

input:

300000
568798613 233084095 327861512 590650711 239351933 324691081 795633639 761256771 495725887 108334978 34291369 357859098 296600277 462147250 691922856 560605458 967297306 997735073 387031649 635544872 752595791 555116508 916702200 742254490 71627927 733049204 245487025 988511083 21276282 574735...

output:

899941
1 2 3 4 5 7 8 9 10 11 13 14 16 17 18 19 20 21 22 23 24 25 27 28 29 30 31 32 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 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 102 103 104 105 10...

result:

ok 899942 numbers

Test #61:

score: 0
Accepted
time: 76ms
memory: 122912kb

input:

300000
746882037 101600236 921642065 56471676 73476994 14394049 375662518 104440759 421692747 390639161 708551809 269161945 529367664 636716787 764150075 488310272 660610437 2239527 260462371 634617625 44883731 30040093 431809709 259096169 93941784 603359412 958581246 863903240 194733699 467035612 8...

output:

899963
1 3 4 5 6 7 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 30 31 32 33 34 35 36 37 38 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 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 94 95 96 97 98 99 100 101 102 103 104 1...

result:

ok 899964 numbers

Test #62:

score: 0
Accepted
time: 65ms
memory: 122776kb

input:

300000
792837885 389432708 826207378 338869224 264793027 857133225 961511186 147080642 541486599 960826178 158415704 701777930 880667971 95405780 321639998 756245880 670084051 397113962 912056772 31677575 103529845 277108496 571421579 234083318 617169359 690350167 165222744 699138888 815686889 71060...

output:

899948
1 2 3 5 6 7 8 9 10 12 13 14 15 16 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 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 100 101 102 103 104...

result:

ok 899949 numbers

Test #63:

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

input:

1
132183177 734230841
544400974 738032622
975726391 40073041

output:

0

result:

ok 1 number(s): "0"