QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#463098 | #8469. Comedy’s Not Omnipotent | ucup-team052 | AC ✓ | 412ms | 8736kb | C++23 | 20.4kb | 2024-07-04 13:45:10 | 2024-07-04 13:45:10 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
#define pb push_back
#define eb emplace_back
mt19937 rnd(chrono::steady_clock::now().time_since_epoch().count());
#define mod 998244353
#define ll long long
#define inf 0x3f3f3f3f
#define INF 0x3f3f3f3f3f3f3f3f
inline int read()
{
char ch=getchar(); int nega=1; while(!isdigit(ch)) {if(ch=='-') nega=-1; ch=getchar();}
int ans=0; while(isdigit(ch)) {ans=ans*10+ch-48;ch=getchar();}
if(nega==-1) return -ans;
return ans;
}
void print(vector<int> x){for(int i=0;i<(int)x.size();i++) printf("%d%c",x[i]," \n"[i==(int)x.size()-1]);}
#define N 100005
const int S=12;
typedef bitset<1<<S> Bit;
struct CMP
{
bool operator () (const Bit &x,const Bit &y) const
{
Bit w=x^y; int pos=w._Find_first();
if(pos<1<<S) return x[pos]<y[pos];
else return 0;
}
};
map<Bit,int,CMP> id;
int op[10005]={0,127,3968,0,384,512,1024,0,0,0,128,0,0,384,512,0,1024,0,0,640,1024,0,0,1152,0,0,0,0,0,384,0,640,0,1152,0,0,0,1024,0,0,512,1024,0,0,0,384,128,0,0,512,0,1024,0,0,0,3969,14,16,32,0,0,0,2,4,0,0,0,390,521,1040,32,0,0,2096,0,0,0,0,561,1024,0,0,1,0,0,16,0,0,0,248,514,1024,0,0,1026,0,0,0,0,24,32,0,0,8,0,0,24,32,0,0,8,0,0,130,0,2,0,0,0,414,1568,0,513,0,1,0,0,0,2592,0,0,0,0,1566,2208,0,1,0,0,32,0,0,0,672,0,288,0,0,0,288,0,0,0,0,514,4,8,0,0,0,1030,8,0,0,0,0,0,6,8,0,0,2,0,0,742,1032,0,8,0,0,0,1160,530,0,0,0,1282,0,0,0,0,8,0,0,0,794,1024,0,0,1026,32,0,0,0,0,268,0,0,0,0,2,0,0,6,8,0,0,2,0,0,926,0,129,288,0,32,0,0,0,257,32,0,0,1024,0,0,1024,0,0,1024,0,0,3230,0,161,1024,0,0,1024,0,0,256,0,0,1312,0,544,0,0,0,544,0,0,0,0,258,4,8,0,0,0,518,8,0,0,0,0,0,6,8,0,0,2,0,0,1158,8,0,0,2186,0,160,4,0,0,0,0,258,0,0,0,256,0,0,1282,0,1544,0,0,0,0,2186,0,0,0,0,0,258,0,2,0,0,0,6,8,0,0,2,0,0,143,16,32,0,0,0,434,0,193,4,0,0,512,0,1024,0,0,0,832,16,0,0,2,0,0,1024,0,0,528,0,1040,0,0,0,1024,0,0,263,0,265,2,0,0,512,0,1024,0,0,512,0,1024,0,0,1538,0,513,0,1,0,0,0,2562,0,0,0,0,1,14,16,32,0,0,0,2,4,0,0,0,384,128,0,0,512,0,1024,0,0,0,3975,24,0,40,0,8,0,0,0,0,952,1,2,0,0,0,3145,18,0,2,0,0,0,17,2,0,0,0,0,1104,0,0,16,0,0,0,1024,0,0,456,1024,0,0,592,1024,0,0,1024,0,0,0,0,144,8,0,0,16,0,0,0,128,0,0,152,264,0,8,0,0,0,168,256,0,0,0,0,0,2041,0,2058,0,19,32,0,0,0,0,18,0,32,0,0,0,0,410,548,0,1,0,0,32,0,0,0,486,8,0,0,520,0,8,0,0,0,544,0,32,0,0,0,160,0,32,0,0,0,738,8,0,0,1034,0,0,0,0,288,8,0,0,0,0,32,0,0,136,0,8,0,0,0,393,528,0,1072,0,0,0,32,0,0,2224,512,0,0,2648,0,16,0,0,0,0,0,336,512,0,0,512,0,0,0,0,208,0,0,0,0,177,0,193,16,0,0,512,0,0,1,0,0,273,0,1,0,0,0,0,16,0,0,128,0,0,408,0,168,0,288,0,0,512,0,0,520,0,0,0,680,0,72,0,128,0,0,0,200,0,264,0,0,0,264,0,0,0,0,72,0,128,0,0,0,0,168,520,0,0,0,288,512,0,0,0,0,0,0,2041,0,2433,512,0,0,128,0,0,2,0,0,2234,256,512,0,0,0,259,512,0,0,1,0,0,512,0,0,0,459,528,0,16,0,0,0,520,16,0,0,0,0,578,0,0,0,0,1,0,0,460,528,0,16,0,0,0,520,16,0,0,0,0,346,0,0,0,0,0,8,16,0,0,0,394,2577,32,0,0,33,0,0,0,1072,0,0,0,0,1726,0,208,0,0,0,2569,0,0,16,0,0,0,0,704,16,0,0,16,0,0,2,0,0,0,148,0,2,0,0,512,0,0,512,0,0,1682,0,780,0,32,0,0,0,0,802,0,8,0,0,0,32,0,0,0,736,0,8,0,0,32,0,0,32,0,0,512,0,0,520,16,32,0,0,0,1154,0,0,0,128,0,0,0,2488,0,192,8,16,0,0,0,512,0,0,512,0,0,2760,16,0,0,784,0,8,0,0,0,0,264,16,0,0,8,0,0,0,25,0,0,0,0,2776,0,9,0,0,0,328,0,8,0,0,16,0,0,0,776,0,8,0,0,8,0,0,0,8,0,0,200,512,0,0,656,0,16,0,0,8,0,0,0,336,512,0,0,512,0,0,0,0,0,8,0,16,0,0,408,128,0,0,680,0,48,0,16,0,0,0,72,0,8,0,0,0,0,680,0,72,0,8,0,0,0,48,0,16,0,0,0,0,512,0,0,2041,384,512,0,0,128,0,0,2433,0,640,0,128,0,0,0,898,0,2,0,0,0,0,130,0,2,0,0,0,2442,0,129,16,32,0,0,0,514,0,0,0,512,0,0,2716,0,128,0,0,675,0,0,1,0,0,0,0,802,0,16,0,0,2,0,0,0,176,0,16,0,0,16,0,0,0,405,0,672,0,288,0,0,0,288,0,0,0,0,658,0,128,0,0,2,0,0,128,0,0,0,35,0,0,0,0,520,16,32,0,0,0,1154,0,0,0,128,0,0,0,2201,34,0,2,0,0,0,162,8,0,0,266,0,512,0,0,0,0,322,0,512,0,0,0,512,0,0,256,0,512,0,0,2411,0,260,0,0,512,0,0,530,0,0,8,0,0,0,545,0,0,0,0,544,0,32,0,0,0,480,8,0,0,520,0,8,0,0,0,544,0,32,0,0,0,32,0,0,264,512,0,0,520,0,0,0,0,393,144,0,304,0,0,0,32,0,0,2224,0,2264,0,0,0,0,145,0,16,0,0,0,0,336,0,0,512,0,0,512,0,0,512,0,0,529,32,0,0,1057,0,16,0,0,0,0,2568,0,32,0,0,128,0,0,0,0,512,0,0,24,0,40,0,8,0,0,0,0,4025,384,0,640,0,1152,0,0,0,1024,0,0,512,1024,0,0,0,962,128,256,0,0,0,388,0,128,0,0,1152,0,128,0,0,0,1024,0,0,131,0,256,0,0,1026,0,0,0,1280,0,256,0,0,0,3266,0,1024,0,0,0,256,0,0,1024,0,0,410,193,0,0,0,0,453,128,0,0,136,0,8,0,0,0,512,0,1024,0,0,512,0,1024,0,0,1698,520,0,8,0,0,0,2058,0,0,0,0,296,0,0,512,0,0,0,520,0,1032,0,0,0,1024,0,0,472,128,0,0,160,8,0,0,8,0,0,512,0,1024,0,0,616,0,1032,0,0,0,1024,0,0,0,8,0,0,8,0,16,0,0,2041,384,128,0,0,512,0,0,130,0,258,0,512,0,0,0,2305,0,0,512,0,0,2058,0,19,32,0,0,0,0,18,0,32,0,0,0,0,24,32,0,0,8,0,0,1,0,2,0,0,3975,24,8,0,0,32,0,0,1976,9,18,0,2,0,0,0,17,2,0,0,0,0,0,2137,10,0,2,0,0,0,35,0,0,8,0,0,9,0,0,0,0,152,264,512,0,0,520,0,0,0,0,416,512,0,0,32,0,0,8,0,0,0,384,512,0,0,128,0,0,4024,1,0,2,0,0,11,17,0,1,0,0,0,13,16,0,0,0,0,0,395,528,1024,0,0,1040,0,0,0,0,412,513,1024,0,0,1025,0,0,0,0,513,1024,0,0,1025,0,0,0,0,520,128,0,0,1024,0,0,0,128,0,0,1549,144,0,16,0,0,0,145,0,0,16,0,0,0,390,0,512,0,0,128,0,0,512,0,0,129,0,1,0,0,0,393,514,1024,0,0,1026,0,0,0,0,435,528,1024,0,0,1040,0,0,0,0,528,1024,0,0,1040,0,0,0,0,513,128,0,0,1024,0,0,0,128,0,0,1553,130,0,2,0,0,0,146,0,0,2,0,0,0,520,128,0,0,16,0,0,0,512,0,0,144,0,16,0,0,0,392,512,0,1024,0,0,1544,128,0,0,640,0,128,0,0,0,528,0,16,0,0,0,16,0,0,656,1024,0,0,1296,0,128,0,0,0,0,160,0,1024,0,0,8,0,0,0,16,0,0,384,512,0,1024,0,0,640,1024,0,0,1152,0,0,0,0,0,952,1088,0,1,0,2,0,0,1,0,2,0,0,3193,128,256,0,0,0,1987,8,16,0,0,0,8,16,0,0,0,128,256,0,0,0,128,256,0,0,0,1034,16,0,0,2066,0,8,0,0,0,0,12,16,0,0,0,0,0,10,16,0,0,18,0,0,0,0,8,16,0,0,0,3545,0,33,8,0,0,128,0,0,2,0,0,3683,136,0,8,0,0,0,160,8,0,0,0,0,160,8,0,0,0,0,1024,0,0,1024,0,0,1250,8,0,0,2764,0,0,0,0,0,0,1868,0,0,33,0,0,0,10,0,0,0,0,0,2468,8,0,0,0,8,0,0,2,0,0,0,258,0,0,0,0,462,0,1032,0,0,0,1562,128,0,0,128,0,0,0,1,0,0,0,1154,0,258,0,0,0,258,0,0,0,0,1154,0,258,0,0,0,258,0,0,0,0,1160,0,264,0,0,0,144,0,16,0,0,0,0,459,1024,0,0,1139,16,0,0,1688,0,0,0,0,1157,0,0,0,0,2113,0,0,0,1228,1,0,0,1425,0,1,0,0,1,0,0,1,0,0,0,1177,0,8,0,0,10,0,0,0,9,0,0,0,8,0,0,3792,0,16,0,0,8,0,0,4,0,0,8,0,0,16,0,0,725,1024,0,0,1170,0,1,0,0,16,0,0,16,0,0,1193,0,131,0,0,0,1,0,0,1,0,0,0,876,1024,0,0,0,16,0,0,1,0,0,0,273,0,1,0,0,0,0,0,177,0,257,0,0,0,25,0,0,0,16,0,0,1,0,0,3544,137,2,0,0,146,0,1,0,0,0,0,17,2,0,0,0,0,0,163,0,133,0,0,0,301,0,0,0,0,9,0,1,0,0,0,1761,2,0,0,0,328,0,0,0,1288,0,0,0,0,8,0,0,1184,0,128,0,0,1544,0,0,0,0,328,0,0,0,1024,0,0,1984,128,0,256,0,0,128,0,256,0,0,8,0,16,0,0,0,1976,0,2497,512,0,0,129,512,0,0,0,0,513,128,0,0,2,0,0,2,0,0,130,0,2,0,0,0,449,520,16,0,0,1048,0,0,0,0,1603,136,16,0,0,280,0,0,0,0,520,16,0,0,1048,0,0,0,0,520,16,0,0,1048,0,0,0,0,0,1738,16,0,0,274,0,8,0,0,0,0,12,16,0,0,0,0,581,0,0,0,0,513,0,0,0,642,0,258,0,0,0,132,0,0,1,0,0,0,2,0,0,2505,16,0,0,406,2,0,0,19,0,0,0,640,0,128,0,0,0,640,0,128,0,0,0,2778,0,34,0,128,0,0,0,418,0,128,0,0,17,0,0,0,128,0,0,0,407,0,0,129,0,0,0,258,0,0,0,0,141,0,0,0,0,0,2770,0,164,0,0,0,0,523,0,0,1,0,0,2,0,0,0,3420,0,0,0,258,0,0,0,0,0,810,0,0,162,0,0,0,0,0,0,34,0,128,0,0,0,0,2641,2,0,0,162,0,2,0,0,2,0,0,0,650,0,1,0,0,2,0,0,2,0,0,0,1168,0,8,0,0,0,0,128,0,0,179,513,0,0,0,513,0,0,0,16,0,0,0,971,128,256,0,0,0,156,257,0,1,0,0,0,269,0,0,8,0,0,0,1288,0,0,16,0,0,0,0,468,1,0,0,161,0,1,0,0,1,0,0,0,673,0,1,0,0,9,0,0,0,13,0,0,0,0,1613,0,0,0,128,0,0,128,0,0,1744,0,0,0,0,0,2457,128,0,0,161,2,0,0,2,0,0,513,0,0,0,0,1745,0,0,0,35,0,0,0,0,0,1249,0,0,1,0,0,0,0,513,0,0,128,0,0,0,949,128,0,256,0,0,128,0,256,0,0,18,0,0,0,16,0,0,1,0,0,2265,10,0,2,0,0,0,162,0,41,0,0,0,264,0,520,0,0,0,512,0,0,264,0,520,0,0,0,512,0,0,2401,2,0,0,514,0,2,0,0,0,168,0,0,0,520,0,8,0,0,0,8,0,0,2536,0,512,0,0,8,0,0,520,0,0,0,512,0,0,256,0,512,0,0,192,0,256,0,512,0,0,8,0,16,0,0,0,953,129,256,0,0,1,0,0,1217,1304,0,257,0,0,0,296,0,0,0,8,0,0,1865,1,16,0,0,0,1288,0,0,0,256,0,0,0,390,2,0,0,2,0,0,1,0,0,0,2,0,0,3545,1184,0,1,0,0,128,0,0,0,3115,0,1680,0,0,128,0,0,0,1184,0,128,0,0,8,0,0,0,0,0,1250,328,0,0,0,1893,8,0,0,8,0,0,2,0,0,0,0,709,0,8,0,0,3,0,0,0,0,0,3,0,0,32,0,0,0,1770,0,1042,0,0,0,0,2898,0,0,8,0,0,0,0,2902,0,0,0,8,0,0,0,524,0,0,0,0,0,10,0,2,0,0,0,3290,1024,0,0,166,1032,0,8,0,0,0,1026,0,0,0,1280,0,256,0,0,0,0,1516,0,180,0,0,0,0,2197,0,32,0,0,1,0,0,8,0,0,0,142,0,0,2,0,0,256,0,0,0,9,0,0,0,0,3373,1024,0,0,1035,0,2,0,0,1,0,0,8,0,0,0,459,0,0,16,0,0,1024,0,0,1024,0,0,180,0,0,1,0,0,0,0,0,457,0,306,0,0,0,0,1326,0,0,0,0,0,1041,0,0,0,0,0,256,0,0,3288,2,0,0,10,0,2,0,0,0,142,0,1032,0,0,0,1026,0,2,0,0,0,1026,0,2,0,0,0,1057,2,0,0,2123,0,0,0,0,200,0,0,0,264,0,8,0,0,0,9,0,0,256,0,0,0,1032,0,2072,0,0,0,1,0,16,0,0,1945,161,0,193,0,256,0,512,0,0,256,0,512,0,0,257,0,513,0,1,0,0,0,0,2529,2184,0,1,0,0,8,0,0,0,2584,0,1,32,0,0,0,8,0,0,8,0,0,162,0,66,0,0,0,66,0,0,0,0,546,0,66,0,0,0,3,0,0,32,0,0,1,0,0,2026,384,128,0,0,512,0,0,402,128,0,0,512,0,0,128,0,0,512,0,0,139,32,0,0,33,0,0,0,0,256,0,512,0,0,2092,0,1,0,0,13,0,0,0,0,0,32,0,0,2058,0,2096,0,0,0,0,3,0,32,0,0,0,0,0,1977,129,1,0,0,256,0,512,0,0,73,16,0,0,1,0,0,2,0,0,10,16,0,0,18,0,0,0,0,0,3975,0,1977,10,0,18,0,0,0,16,0,0,73,2,0,0,1,0,0,16,0,0,129,256,512,0,0,0,1,0,0,1945,0,2058,0,3,0,32,0,0,0,2096,0,0,0,0,0,2026,32,0,0,2092,0,0,13,0,0,0,1,0,0,0,139,256,512,0,0,0,0,33,0,0,0,32,0,0,402,512,0,0,128,0,0,512,0,0,128,0,0,384,512,0,0,128,0,0,2529,546,1,0,0,3,32,0,0,0,0,66,0,0,0,0,162,0,66,0,0,0,66,0,0,0,0,2584,8,0,0,8,0,0,1,0,32,0,0,0,2184,0,8,0,0,1,0,0,0,161,257,0,513,0,1,0,0,0,0,193,256,512,0,0,0,256,512,0,0,0,0,0,953,1032,1,16,0,0,0,2072,0,0,0,0,3288,0,9,256,0,0,0,0,1057,264,0,8,0,0,0,200,0,0,0,2123,0,0,0,0,2,0,0,142,1026,0,2,0,0,0,1026,0,2,0,0,0,1032,0,0,0,0,10,0,2,0,0,0,2,0,0,3290,256,0,0,457,0,1041,0,0,0,0,1326,0,0,0,0,0,306,0,0,0,0,0,3373,0,180,0,0,1,0,0,0,0,459,1024,0,0,1024,0,0,16,0,0,0,0,1035,0,8,0,0,1,0,0,2,0,0,0,1024,0,0,1516,0,9,0,0,0,142,0,256,0,0,2,0,0,0,0,2197,0,8,0,0,1,0,0,32,0,0,0,180,0,0,0,0,0,166,0,1280,0,256,0,0,0,1026,0,0,0,1032,0,8,0,0,0,1024,0,0,3545,10,0,2,0,0,0,1770,0,524,0,0,0,0,2902,0,8,0,0,0,0,0,2898,0,0,8,0,0,0,0,1042,0,0,0,0,0,1250,0,3,32,0,0,0,0,709,0,0,3,0,0,0,8,0,0,0,1893,0,0,2,0,0,8,0,0,8,0,0,328,0,0,0,3115,0,0,1184,0,8,0,0,128,0,0,0,1680,0,128,0,0,0,0,0,1184,0,128,0,0,1,0,0,0,1217,2,0,0,390,0,1,0,0,2,0,0,2,0,0,1865,0,256,0,0,1288,0,0,0,1,0,16,0,0,1304,8,0,0,296,0,0,0,257,0,0,0,0,129,1,0,0,256,0,0,1976,0,192,8,16,0,0,0,256,512,0,0,0,0,2265,256,512,0,0,0,2536,512,0,0,520,0,0,0,8,0,0,512,0,0,0,2401,8,0,0,520,0,8,0,0,0,168,0,0,0,514,0,2,0,0,0,2,0,0,162,264,512,0,0,520,0,0,0,0,264,512,0,0,520,0,0,0,0,41,0,0,0,0,10,0,2,0,0,0,971,1,0,0,949,16,0,0,18,0,0,0,128,256,0,0,0,128,256,0,0,0,2457,0,513,128,0,0,0,0,1249,0,0,1,0,0,0,0,1745,0,0,35,0,0,0,0,0,0,161,0,513,0,0,0,2,0,0,2,0,0,128,0,0,468,0,1744,0,0,0,0,1613,128,0,0,128,0,0,0,0,0,673,0,13,0,0,0,9,0,0,0,1,0,0,0,161,0,1,0,0,1,0,0,0,1,0,0,156,0,1288,0,16,0,0,0,0,269,0,8,0,0,0,0,257,0,1,0,0,0,128,0,256,0,0,2505,0,179,16,0,0,513,0,0,0,513,0,0,0,2641,128,0,0,1168,0,0,8,0,0,0,650,0,2,0,0,2,0,0,1,0,0,0,162,0,2,0,0,2,0,0,0,2,0,0,2770,0,34,0,128,0,0,0,810,0,0,162,0,0,0,0,0,0,3420,0,0,258,0,0,0,0,0,0,523,0,2,0,0,1,0,0,0,0,164,0,0,0,0,0,2778,0,141,0,0,0,0,407,0,258,0,0,0,129,0,0,0,0,0,418,0,128,0,0,17,0,0,0,128,0,0,0,34,0,128,0,0,0,0,406,640,0,128,0,0,0,640,0,128,0,0,0,19,0,0,0,2,0,0,16,0,0,449,2,0,0,642,0,132,1,0,0,0,0,258,0,0,0,0,1738,513,0,0,0,581,0,0,0,0,12,0,0,16,0,0,274,0,0,8,0,0,0,16,0,0,1603,0,520,0,1048,0,0,0,16,0,0,520,0,1048,0,0,0,16,0,0,136,0,280,0,0,0,16,0,0,520,0,1048,0,0,0,16,0,0,2497,130,0,2,0,0,0,513,2,0,0,2,0,0,128,0,0,129,0,0,512,0,0,512,0,0,0,952,0,1984,8,16,0,0,0,128,256,0,0,0,128,256,0,0,0,3544,1024,0,0,1184,328,0,0,0,1544,0,0,0,0,128,0,0,0,1761,8,0,0,1288,0,0,0,0,328,0,0,0,0,2,0,0,163,9,0,1,0,0,0,301,0,0,0,0,133,0,0,0,0,137,0,17,0,0,2,0,0,146,0,0,1,0,0,0,2,0,0,459,1,0,0,177,16,0,0,25,0,0,0,257,0,0,0,0,725,0,273,0,0,1,0,0,0,876,0,1,0,0,16,0,0,0,1024,0,0,1193,0,1,0,0,1,0,0,131,0,0,0,0,1170,16,0,0,16,0,0,1,0,0,0,1024,0,0,1228,16,0,0,3792,8,0,0,4,0,0,8,0,0,16,0,0,0,1177,8,0,0,9,0,0,0,10,0,0,0,8,0,0,0,1425,0,1,0,0,1,0,0,1,0,0,0,1,0,0,1139,2113,0,0,0,1157,0,0,0,0,1688,0,0,0,0,16,0,0,1024,0,0,3545,1160,0,144,0,16,0,0,0,264,0,0,0,0,462,1154,0,258,0,0,0,258,0,0,0,0,1154,0,258,0,0,0,258,0,0,0,0,1562,0,1,0,0,0,128,0,0,128,0,0,1032,0,0,0,0,1250,0,258,0,0,0,2468,0,2,0,0,8,0,0,0,8,0,0,1868,0,0,10,0,0,0,33,0,0,0,0,0,2764,0,0,0,0,0,0,8,0,0,3683,1024,0,0,1024,0,0,160,0,0,8,0,0,160,0,0,8,0,0,136,0,8,0,0,0,33,2,0,0,128,0,0,8,0,0,0,3193,8,0,16,0,0,10,0,18,0,0,0,16,0,0,1034,0,12,0,0,16,0,0,2066,0,0,8,0,0,0,16,0,0,1987,128,0,256,0,0,128,0,256,0,0,8,0,16,0,0,8,0,16,0,0,128,0,256,0,0,1088,1,2,0,0,0,1,2,0,0,0,0,4024,384,0,640,0,1152,0,0,0,1024,0,0,512,1024,0,0,0,392,16,0,0,656,0,160,8,0,0,1024,0,0,0,1296,0,0,128,0,0,0,1024,0,0,1544,16,0,0,528,0,16,0,0,0,640,0,128,0,0,0,128,0,0,512,1024,0,0,0,393,144,0,16,0,0,0,1553,512,0,0,520,0,16,0,0,128,0,0,146,0,2,0,0,0,0,130,0,2,0,0,0,435,128,0,0,513,0,1024,0,0,128,0,0,528,0,1040,0,0,0,1024,0,0,528,0,1040,0,0,0,1024,0,0,514,0,1026,0,0,0,1024,0,0,395,129,0,1,0,0,0,1549,512,0,0,390,128,0,0,512,0,0,0,145,0,16,0,0,0,0,144,0,16,0,0,0,412,128,0,0,520,0,1024,0,0,128,0,0,513,0,1025,0,0,0,1024,0,0,513,0,1025,0,0,0,1024,0,0,528,0,1040,0,0,0,1024,0,0,11,0,13,0,0,16,0,0,17,0,1,0,0,0,1,2,0,0,0,1976,384,128,0,0,512,0,0,152,0,416,8,0,0,32,0,0,512,0,0,264,0,520,0,0,0,512,0,0,2137,0,9,0,0,0,35,8,0,0,0,0,10,0,2,0,0,0,9,0,17,0,0,2,0,0,18,0,2,0,0,0,24,32,0,0,8,0,0,3975,1,2,0,0,0,2041,24,8,0,0,32,0,0,2058,0,18,0,32,0,0,0,19,0,0,32,0,0,0,130,2305,512,0,0,0,0,258,0,512,0,0,0,0,384,512,0,0,128,0,0,4025,8,16,0,0,0,472,8,0,0,616,0,1024,0,0,1032,0,0,0,0,160,512,1024,0,0,0,8,0,0,8,0,0,128,0,0,410,520,1024,0,0,1032,0,0,0,0,1698,0,296,512,0,0,0,0,2058,0,0,0,0,520,0,8,0,0,0,453,512,1024,0,0,0,512,1024,0,0,0,136,0,8,0,0,0,128,0,0,193,0,0,0,0,962,1024,0,0,3266,256,0,0,0,1024,0,0,0,131,1280,0,256,0,0,0,1026,0,0,0,256,0,0,0,388,1024,0,0,1152,0,128,0,0,0,128,0,0,0,128,0,256,0,0,384,512,0,1024,0,0,640,1024,0,0,1152,0,0,0,0,0,2041,24,0,40,0,8,0,0,0,0,393,512,0,0,529,0,2568,0,128,0,0,32,0,0,0,1057,0,0,16,0,0,0,32,0,0,2224,512,0,0,336,512,0,0,512,0,0,0,0,145,0,0,16,0,0,0,2264,0,0,0,0,0,144,32,0,0,304,0,0,0,0,2201,264,0,520,0,0,0,512,0,0,480,32,0,0,544,0,32,0,0,0,520,0,8,0,0,0,8,0,0,2411,544,0,32,0,0,0,545,0,0,0,0,530,0,8,0,0,0,0,260,512,0,0,0,0,0,162,256,512,0,0,0,322,512,0,0,0,512,0,0,0,266,0,0,512,0,0,0,8,0,0,34,0,2,0,0,0,2442,0,520,128,0,0,1154,0,0,0,16,0,32,0,0,405,0,35,0,0,0,658,0,128,0,0,2,0,0,128,0,0,0,672,0,288,0,0,0,288,0,0,0,0,0,2716,0,176,16,0,0,16,0,0,0,802,0,2,0,0,16,0,0,0,675,0,0,1,0,0,0,0,128,0,0,0,129,512,0,0,514,0,0,0,16,0,32,0,0,0,2433,130,0,2,0,0,0,898,0,0,2,0,0,0,640,0,128,0,0,0,0,384,128,0,0,512,0,0,2041,408,512,0,0,680,0,48,0,16,0,0,0,72,0,8,0,0,0,0,680,0,72,0,8,0,0,0,48,0,16,0,0,0,0,128,0,0,2488,8,16,0,0,0,200,0,336,0,0,512,0,0,512,0,0,656,0,8,0,0,16,0,0,0,512,0,0,2776,8,0,0,776,0,8,0,0,8,0,0,0,328,0,16,0,0,8,0,0,0,9,0,0,0,0,2760,0,25,0,0,0,264,0,8,0,0,16,0,0,784,0,0,8,0,0,0,16,0,0,192,512,0,0,512,0,0,8,0,16,0,0,0,394,0,520,128,0,0,1154,0,0,0,16,0,32,0,0,1682,512,0,0,736,32,0,0,32,0,0,8,0,0,0,802,0,32,0,0,0,8,0,0,0,780,0,0,32,0,0,0,0,1726,148,512,0,0,512,0,0,2,0,0,0,704,0,2,0,0,16,0,0,16,0,0,2569,0,0,16,0,0,0,0,208,0,0,0,0,2577,0,1072,0,0,0,33,0,0,0,32,0,0,2234,8,0,16,0,0,460,0,346,0,0,0,0,520,0,0,16,0,0,528,0,16,0,0,0,459,1,0,0,578,0,0,0,0,520,0,0,16,0,0,528,0,16,0,0,0,259,0,512,0,0,1,0,0,512,0,0,256,0,512,0,0,2433,2,0,0,128,0,0,512,0,0,0,2041,408,0,168,0,288,0,0,512,0,0,520,0,0,0,680,0,72,0,128,0,0,0,200,0,264,0,0,0,264,0,0,0,0,72,0,128,0,0,0,0,168,520,0,0,0,288,512,0,0,0,0,0,0,393,128,0,0,177,16,0,0,273,0,0,1,0,0,0,193,1,0,0,512,0,0,16,0,0,0,2224,0,208,0,0,0,336,0,0,512,0,0,512,0,0,2648,0,0,0,16,0,0,0,512,0,0,528,32,0,0,1072,0,0,0,0,410,136,0,8,0,0,0,738,32,0,0,288,0,0,8,0,0,1034,0,0,0,0,8,0,0,486,160,0,32,0,0,0,544,0,32,0,0,0,520,0,8,0,0,0,8,0,0,548,0,32,0,0,1,0,0,0,2058,0,18,0,32,0,0,0,19,0,0,32,0,0,0,0,952,152,0,168,0,0,256,0,0,264,0,8,0,0,0,456,128,0,0,144,0,16,0,0,8,0,0,592,0,0,1024,0,0,1024,0,0,1024,0,0,3145,1024,0,0,1104,0,16,0,0,0,0,17,0,0,2,0,0,18,0,2,0,0,0,1,0,2,0,0,24,0,40,0,8,0,0,0,0,3969,0,1,384,512,1024,0,0,0,128,0,0,14,2,0,4,0,0,16,0,32,0,0,143,263,1538,0,2562,0,0,0,513,0,1,0,0,0,0,265,512,1024,0,0,0,512,1024,0,0,0,2,0,0,0,434,528,1024,0,0,1040,0,0,0,0,832,1024,0,0,2,0,0,16,0,0,193,0,512,1024,0,0,0,4,0,0,0,16,0,32,0,0,926,6,2,0,0,8,0,0,1158,258,0,2,0,0,0,1282,0,2186,0,0,0,0,1544,0,0,0,0,0,2186,256,0,0,258,0,0,0,160,0,0,4,0,0,0,8,0,0,3230,6,2,0,0,8,0,0,258,0,518,0,0,8,0,0,4,0,8,0,0,1312,0,544,0,0,0,544,0,0,0,0,161,256,0,0,1024,0,0,1024,0,0,0,129,1024,0,0,257,1024,0,0,1024,0,0,32,0,0,288,0,32,0,0,0,0,414,6,2,0,0,8,0,0,742,2,0,0,794,0,268,0,0,0,1026,0,0,32,0,0,1024,0,0,1160,0,8,0,0,1282,0,0,0,0,530,0,0,0,1032,0,8,0,0,0,1566,6,2,0,0,8,0,0,514,0,1030,0,0,8,0,0,4,0,8,0,0,672,0,288,0,0,0,288,0,0,0,0,2208,0,32,0,0,1,0,0,0,1568,0,2592,0,0,0,513,0,1,0,0,0,0,390,130,0,2,0,0,0,248,24,8,0,0,32,0,0,24,8,0,0,32,0,0,514,0,1026,0,0,0,1024,0,0,521,0,561,16,0,0,1,0,0,1024,0,0,1040,0,2096,0,0,0,32,0,0,14,2,0,4,0,0,16,0,32,0,0,3968,0,384,512,1024,0,0,0,128,0,0,384,512,0,1024,0,0,640,1024,0,0,1152,0,0,0,0,0,384,0,640,0,1152,0,0,0,1024,0,0,512,1024,0,0,0,384,128,0,0,512,0,1024,0,0,0,};
int ch[10005][S+1],cnt;
int getres(int st,int q)
{
return __builtin_popcount(st&q);
}
int build(Bit cur,int dep)
{
if(id.find(cur)!=id.end()) return id.count(cur);
id[cur]=++cnt;
// st[cnt]=cur;
if(cur.count()==1) return id[cur];
int I=cnt;
/*
int pcc[S][2]; memset(pcc,0,sizeof(pcc));
for(int j=cur._Find_first();j<1<<S;j=cur._Find_next(j))
{
for(int k=0;k<S;k++) pcc[k][j>>k&1]++;
}
int tid=-1,mn=inf;
for(int k=0;k<S;k++)
{
if(abs(pcc[k][0]-pcc[k][1])<mn) mn=abs(pcc[k][0]-pcc[k][1]),tid=k;
}
int go=0,mxw=-1,mnw=0;
for(int i=1;i<1<<S;i++)
{
if(dep==0&&i!=(1<<7)-1) continue;
else if(!(i>>tid&1)) continue;
Bit tr[S+1];
for(int j=cur._Find_first();j<1<<S;j=cur._Find_next(j)) tr[getres(j,i)].set(j);
int cnt=0,mx=0;
for(int j=0;j<=S;j++)
{
int c=tr[j].count();
if(c) cnt++,mx=max(mx,c);
}
if(cnt>mxw) mxw=cnt,mnw=mx,go=i;
else if(cnt==mxw&&mx<mnw) mnw=mx,go=i;
}
op[I]=go;
*/
int go=op[I];
Bit tr[S+1];
for(int j=cur._Find_first();j<1<<S;j=cur._Find_next(j)) tr[getres(j,go)].set(j);
for(int j=0;j<=S;j++)
{
if(tr[j].none()) continue;
ch[I][j]=build(tr[j],dep+1);
}
return I;
}
void init()
{
Bit f; f.set();
build(f,0);
// cout<<cnt<<endl;
int sum=0;
for(int i=0;i<1<<S;i++)
{
int cur=1;
while(op[cur])
{
sum++;
cur=ch[cur][getres(i,op[cur])];
}
}
// printf("%lf\n",(double)sum/(1<<S)/S);
}
int ANS[N],n,a[N],b[N];
int qcnt,qsum;
int query(vector<int> v)
{
#ifdef wasa855
int ans=0;
qcnt++,qsum+=v.size();
for(int i:v) ans+=ANS[i];
return ans;
#else
printf("? %d ",(int)v.size());
print(v); fflush(stdout);
return read();
#endif
}
signed main()
{
init();
n=read();
#ifdef wasa855
for(int i=1;i<=n;i++) ANS[i]=rnd()&1;
#endif
vector<int> cur;
for(int i=1;i<=n;i++)
{
cur.push_back(i);
if((int)cur.size()==S)
{
Bit st; st.set();
int id=1;
while(st.count()>2)
{
int q=op[id];
vector<int> qry;
for(int j=0;j<S;j++) if(q>>j&1) qry.push_back(cur[j]);
int res=query(qry);
Bit nw;
for(int j=st._Find_first();j<1<<S;j=st._Find_next(j))
{
if(getres(j,q)==res) nw.set(j);
}
st=nw;
id=ch[id][res];
}
if(st.count()==1)
{
int ans=st._Find_first();
for(int j=0;j<S;j++) a[cur[j]]=ans>>j&1;
cur.clear();
}
else
{
assert(st.count()==2);
int P=st._Find_first(),Q=st._Find_next(P);
int qid=0;
for(int i=0;i<S;i++) if((P^Q)>>i&1) qid=i;
int pa=P>>qid&1,qa=cur[qid];
for(int i=0;i<S;i++)
{
int p=P>>i&1,q=Q>>i&1;
if(p==q) a[cur[i]]=p;
else
{
if(i==qid) continue;
else a[cur[i]]=-1,b[cur[i]]=pa==p?qa:-qa;
}
}
cur.clear();
cur.push_back(qa);
}
}
}
if(!cur.empty())
{
int tmp=1;
while((int)cur.size()<S) cur.push_back(tmp++);
Bit st; st.set();
int id=1;
while(st.count()>1)
{
int q=op[id];
vector<int> qry;
for(int j=0;j<S;j++) if(q>>j&1) qry.push_back(cur[j]);
int res=query(qry);
Bit nw;
for(int j=st._Find_first();j<1<<S;j=st._Find_next(j))
{
if(getres(j,q)==res) nw.set(j);
}
st=nw;
id=ch[id][res];
}
assert(st.count()==1);
int ans=st._Find_first();
for(int j=0;j<S;j++) a[cur[j]]=ans>>j&1;
cur.clear();
}
for(int i=n;i>=1;i--)
{
if(a[i]==-1)
{
if(b[i]>0) a[i]=a[b[i]];
else a[i]=a[-b[i]]^1;
}
}
#ifdef wasa855
for(int i=1;i<=n;i++) if(a[i]!=ANS[i]) printf("wa %d\n",i);
printf("%d %d\n",qcnt,qsum);
#else
printf("= "); for(int i=1;i<=n;i++) printf("%d",a[i]);
cout<<endl;
#endif
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 412ms
memory: 8516kb
input:
100000 4 7 5 3 1 5 6 7 4 3 1 3 6 5 6 3 4 3 3 3 4 3 3 2 3 0 2 4 4 2 3 1 4 5 5 4 3 2 1 1 0 0 5 3 6 0 0 5 5 5 4 3 0 2 2 2 1 3 1 4 3 3 4 4 4 4 1 2 1 0 4 7 4 2 0 1 1 1 2 0 5 7 3 0 3 2 4 2 2 2 2 1 3 1 0 3 3 5 4 1 4 6 6 3 5 0 4 6 5 3 5 1 0 6 3 5 4 1 2 3 1 2 1 2 3 2 3 1 3 1 2 2 2 1 0 3 2 3 0 0 3 2 3 2 0 1 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 5 1 4 5 7 12 ? 3 1 2 6 ? 7 5 13 14 15 16 17 18 ? 8 5 13 14 19 20 21 22 23 ? 9 5 15 16 17 18 19 20 21 22 ? 5 13 15 16 19 20 ? 6 13 14 17 18 19 20 ? 2 17 19 ? 7 20 24 25 26 27 28 29 ? 8 20 24 25 30 31 32 33 34 ? 7 20 26 27 30 31 32 33 ? 8 ...
result:
ok Sequence is guessed#op = 47838, #bit = 283676
Test #2:
score: 0
Accepted
time: 376ms
memory: 8464kb
input:
100000 5 5 4 2 2 2 4 5 4 6 3 2 2 4 3 1 0 7 1 1 4 4 4 6 2 5 4 2 0 4 5 4 4 4 1 0 1 0 0 4 8 0 2 1 2 3 3 4 3 2 1 1 2 3 2 1 3 3 5 4 5 2 3 2 5 4 2 0 2 2 4 2 0 3 4 5 3 0 2 2 2 0 0 4 5 4 5 3 4 2 3 4 5 3 0 4 2 2 5 0 7 2 1 0 2 3 2 0 0 3 4 2 0 1 1 5 3 4 4 3 2 3 3 2 1 2 3 5 4 5 2 3 2 5 5 2 3 1 3 3 1 1 1 1 1 1 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 4 4 5 8 9 ? 4 4 6 8 10 ? 2 5 6 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 6 16 17 18 20 21 22 ? 8 13 16 17 19 20 21 23 24 ? 7 13 14 18 19 22 23 24 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 9 24 27 28 29 30 31...
result:
ok Sequence is guessed#op = 47903, #bit = 284355
Test #3:
score: 0
Accepted
time: 389ms
memory: 8352kb
input:
100000 5 4 6 3 4 1 4 4 3 6 0 3 1 1 1 0 3 3 5 3 0 4 6 8 0 4 3 2 1 0 5 6 5 1 2 0 6 3 5 4 2 0 4 3 4 4 2 2 1 5 5 6 3 6 4 2 5 5 2 3 1 4 3 4 4 1 0 4 5 4 5 2 5 3 4 1 2 0 4 4 4 4 6 1 4 5 3 4 4 3 3 1 3 2 0 3 6 5 4 4 4 5 3 4 2 2 3 4 4 3 1 2 3 5 3 6 1 5 6 7 5 2 5 5 6 2 2 2 3 2 5 1 0 1 4 1 3 1 2 3 5 2 1 1 2 4 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 2 4 8 9 12 ? 6 3 4 5 8 10 12 ? 5 1 2 6 8 10 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 7 16 17 18 20 21 22 23 ? 7 13 14 16 19 20 21 22 ? 1 20 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 7 28 29 30 32 33 34 35...
result:
ok Sequence is guessed#op = 47918, #bit = 284627
Test #4:
score: 0
Accepted
time: 361ms
memory: 8456kb
input:
100000 4 6 4 1 1 0 6 2 4 2 1 2 4 5 5 4 1 0 4 4 6 1 1 3 4 3 2 4 1 4 5 3 4 3 2 1 5 5 7 3 4 0 6 3 5 4 0 5 5 5 4 3 2 3 4 5 5 1 3 5 5 4 3 0 4 5 4 7 2 3 2 3 1 3 2 4 2 2 5 0 4 5 3 3 3 2 6 4 4 5 2 2 5 4 6 4 2 1 4 4 6 2 0 3 2 2 3 2 6 4 6 1 0 5 6 5 2 2 0 4 5 3 4 4 3 3 5 5 4 0 2 3 5 3 3 0 1 3 3 3 0 4 4 4 2 3 0...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 8 4 5 6 8 9 10 11 12 ? 3 4 8 9 ? 3 5 8 10 ? 2 6 8 ? 7 10 13 14 15 16 17 18 ? 6 10 19 20 21 22 23 ? 5 10 13 14 15 19 ? 5 13 16 17 19 20 ? 2 16 21 ? 2 16 22 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 6 27 28 29 31 32 33 ? 7 24 27 28 29 30 34 35 ? ...
result:
ok Sequence is guessed#op = 47947, #bit = 284655
Test #5:
score: 0
Accepted
time: 351ms
memory: 8376kb
input:
100000 1 2 3 1 2 4 3 4 1 2 3 5 5 4 1 1 4 5 4 4 3 2 0 2 4 4 2 2 0 3 5 4 1 2 3 3 2 2 4 1 2 2 1 1 3 2 5 4 3 3 2 1 1 1 1 0 5 3 6 1 0 1 3 3 0 3 4 3 3 5 1 5 5 8 2 3 7 5 1 6 3 5 5 1 1 4 4 2 2 1 2 1 3 2 4 0 2 2 4 1 0 1 2 1 3 1 2 3 4 3 4 3 3 3 2 3 0 4 3 5 0 3 2 3 2 2 2 2 1 2 0 5 5 7 3 2 2 3 3 1 1 0 0 2 0 1 4...
output:
? 7 1 2 3 4 5 6 7 ? 6 1 8 9 10 11 12 ? 6 2 3 4 5 8 9 ? 2 2 3 ? 7 3 13 14 15 16 17 18 ? 8 3 13 14 19 20 21 22 23 ? 9 3 15 16 17 18 19 20 21 22 ? 5 13 15 19 20 23 ? 2 15 21 ? 3 13 19 22 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 24 27 28 29 31 32 33 ? 6 27 28 30 31 34 35 ? 3 24 29 34 ? 5...
result:
ok Sequence is guessed#op = 47990, #bit = 285306
Test #6:
score: 0
Accepted
time: 337ms
memory: 8632kb
input:
100000 5 5 7 4 4 3 5 4 5 4 2 1 4 6 4 1 1 0 5 5 6 2 1 3 4 3 3 3 5 3 1 2 4 4 3 2 3 2 1 5 5 5 4 3 0 3 6 5 6 2 0 4 5 5 2 1 0 2 1 1 0 3 2 4 2 0 5 5 4 2 2 2 4 3 2 1 1 3 4 4 4 3 2 3 4 3 3 3 4 2 5 4 4 0 2 4 4 1 3 1 3 2 3 2 2 1 3 4 2 2 2 0 2 4 3 4 2 5 7 4 2 0 4 2 2 4 1 4 3 4 6 2 3 3 2 1 1 3 4 2 1 1 2 2 3 2 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 6 2 4 5 6 8 12 ? 6 1 2 4 7 8 9 ? 3 2 7 10 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 5 13 16 17 20 24 ? 3 14 18 20 ? 3 14 16 21 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 8 28 29...
result:
ok Sequence is guessed#op = 48019, #bit = 284918
Test #7:
score: 0
Accepted
time: 325ms
memory: 8660kb
input:
100000 1 0 0 0 5 4 4 2 3 2 3 3 2 4 2 2 3 3 4 4 4 0 4 3 4 5 4 1 4 6 7 2 1 5 3 4 3 3 1 4 5 3 3 3 2 1 4 2 1 2 0 2 1 1 2 2 4 5 2 2 1 3 6 3 5 3 1 5 5 6 2 2 2 3 5 2 1 2 0 3 3 2 4 4 1 2 3 4 4 5 5 4 4 3 3 4 0 6 5 4 2 2 1 4 1 1 1 1 4 3 4 5 3 1 5 5 6 3 6 3 2 1 3 1 2 4 4 4 2 2 3 4 3 4 3 4 1 2 3 3 3 0 1 4 1 2 1...
output:
? 7 1 2 3 4 5 6 7 ? 6 1 8 9 10 11 12 ? 3 2 3 4 ? 1 5 ? 7 7 13 14 15 16 17 18 ? 8 7 13 14 19 20 21 22 23 ? 9 7 15 16 17 18 19 20 21 22 ? 4 7 15 19 20 ? 4 16 17 19 23 ? 5 15 16 18 19 23 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 6 27 28 29 31 32 33 ? 8 24 27 28 30 31 32 34 35 ? 6 25 26 27 ...
result:
ok Sequence is guessed#op = 47778, #bit = 283799
Test #8:
score: 0
Accepted
time: 376ms
memory: 8624kb
input:
100000 5 4 6 3 3 3 3 3 4 2 2 0 4 3 4 4 3 5 5 5 8 4 4 5 3 4 4 5 4 4 3 4 4 1 5 5 5 3 3 3 3 3 4 3 2 2 3 4 4 4 3 4 1 3 4 3 3 2 3 4 2 0 3 1 2 2 0 3 4 3 2 3 4 0 3 3 3 3 1 1 2 4 5 2 3 0 4 3 5 3 1 5 5 6 2 4 3 2 3 5 3 2 2 4 5 2 4 1 1 3 5 3 3 2 1 3 1 3 1 0 4 4 7 4 5 1 3 0 3 5 3 5 3 1 1 1 0 0 0 3 3 3 1 1 4 6 5...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 2 4 8 9 12 ? 6 3 4 5 8 10 12 ? 4 2 6 9 10 ? 7 9 13 14 15 16 17 18 ? 8 9 13 14 19 20 21 22 23 ? 6 15 16 17 19 20 21 ? 7 15 16 18 19 20 22 23 ? 3 9 15 19 ? 2 9 16 ? 7 14 24 25 26 27 28 29 ? 8 14 24 25 30 31 32 33 34 ? 7 14 26 27 28 3...
result:
ok Sequence is guessed#op = 47870, #bit = 283764
Test #9:
score: 0
Accepted
time: 391ms
memory: 8208kb
input:
100000 2 4 5 4 4 6 4 2 1 2 4 4 4 2 3 0 2 1 3 1 1 4 4 4 5 2 1 5 3 4 1 0 4 3 5 0 2 7 0 1 2 2 1 1 1 3 5 3 4 3 5 6 3 6 2 1 4 5 4 6 4 1 5 6 5 2 2 3 5 5 7 5 0 3 4 2 1 2 0 2 5 4 3 1 4 3 3 3 3 1 3 5 3 5 2 2 2 5 4 3 2 2 4 4 4 4 4 2 1 6 2 3 3 3 5 7 6 0 3 5 6 1 2 4 3 4 4 2 2 1 3 3 4 3 2 2 3 6 4 4 1 0 5 2 4 2 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 4 1 4 8 9 ? 7 11 13 14 15 16 17 18 ? 8 11 13 14 19 20 21 22 23 ? 8 15 16 17 19 20 21 22 23 ? 3 15 19 20 ? 3 15 21 22 ? 2 16 21 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 27 28 29 31 32 33 34 ? 6 24 27 30 31 32 35 ? 5 24...
result:
ok Sequence is guessed#op = 47995, #bit = 285086
Test #10:
score: 0
Accepted
time: 295ms
memory: 8376kb
input:
100000 5 3 5 2 2 4 5 4 4 4 2 4 3 1 0 1 4 3 2 2 0 0 4 5 4 4 4 5 4 4 4 4 6 0 3 5 5 6 4 4 6 4 4 4 4 4 3 4 3 5 4 4 4 5 2 4 4 2 2 0 4 3 2 2 1 0 5 7 4 4 4 1 4 0 0 2 5 5 4 1 1 2 4 3 4 2 1 5 0 1 0 4 6 6 3 3 2 5 2 3 2 3 5 4 3 2 0 4 6 3 1 2 5 3 5 3 0 4 5 3 3 4 4 4 3 3 4 3 1 5 4 6 4 1 2 2 5 5 2 2 1 3 3 0 2 1 5...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 8 9 10 11 12 ? 5 2 7 8 9 10 ? 3 1 2 8 ? 7 10 13 14 15 16 17 18 ? 8 10 13 14 19 20 21 22 23 ? 6 15 16 17 19 20 21 ? 8 10 15 16 18 19 20 22 23 ? 6 13 14 15 18 19 20 ? 5 13 15 16 21 22 ? 7 23 24 25 26 27 28 29 ? 8 23 24 25 30 31 32 33 34 ? 7 23 26 27...
result:
ok Sequence is guessed#op = 47886, #bit = 284878
Test #11:
score: 0
Accepted
time: 353ms
memory: 8664kb
input:
100000 3 4 3 3 3 4 0 2 2 3 0 2 3 5 3 3 2 2 3 3 1 4 2 3 2 5 0 0 3 2 2 2 0 2 4 5 3 5 4 2 6 2 3 2 2 0 4 5 5 3 2 2 4 2 1 1 3 5 4 5 4 0 6 2 3 2 1 1 4 0 4 6 6 3 3 3 5 3 5 3 2 1 2 2 1 0 2 2 4 3 4 0 0 1 1 0 1 2 4 5 3 3 6 4 4 3 5 3 2 1 2 1 3 1 3 6 6 2 0 2 5 4 3 3 0 3 4 5 2 2 0 6 3 5 6 1 2 3 2 2 1 0 4 3 2 2 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 6 1 4 7 8 9 12 ? 6 2 5 7 8 10 12 ? 7 3 4 5 7 9 11 12 ? 2 2 9 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 4 13 16 20 21 ? 2 17 22 ? 7 19 25 26 27 28 29 30 ? 8 19 25 26 31 32 33 34 35 ? 7 19 27 28 ...
result:
ok Sequence is guessed#op = 47794, #bit = 284745
Test #12:
score: 0
Accepted
time: 368ms
memory: 8516kb
input:
100000 5 5 7 3 3 3 5 5 6 4 1 2 5 6 5 2 1 0 5 4 6 3 3 2 1 1 0 0 0 3 2 4 1 2 2 3 3 2 5 1 0 2 5 4 3 2 0 4 7 5 3 1 4 5 3 3 4 3 2 3 7 6 1 2 2 3 4 4 1 0 3 5 4 3 3 5 3 4 2 2 1 3 3 4 3 1 4 1 3 3 3 4 3 6 3 6 1 1 4 7 4 2 2 4 4 3 1 3 3 3 3 3 1 5 4 4 2 4 3 5 4 4 4 2 4 4 4 2 3 3 4 5 3 2 3 2 5 3 4 2 1 1 2 4 5 1 0...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 6 2 4 5 6 8 12 ? 5 3 4 7 8 9 ? 5 2 4 5 7 9 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 4 14 16 20 21 ? 4 13 17 22 24 ? 3 17 18 23 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 9 25 2...
result:
ok Sequence is guessed#op = 47699, #bit = 283404
Test #13:
score: 0
Accepted
time: 385ms
memory: 8376kb
input:
100000 6 3 4 2 1 3 3 3 2 4 1 1 3 6 4 3 3 4 5 5 4 1 2 4 4 4 5 3 0 1 3 2 3 0 0 6 5 3 5 2 3 5 4 2 3 1 6 4 5 3 2 4 6 6 4 5 2 3 2 4 1 0 5 5 7 4 5 2 3 4 3 2 3 4 0 4 2 3 1 2 2 3 5 4 2 2 0 4 3 4 5 5 2 5 5 2 3 1 4 5 3 4 3 3 0 3 4 3 4 3 1 7 1 1 3 3 3 3 1 1 4 5 4 5 3 3 1 2 4 3 2 3 3 3 3 2 3 2 2 1 4 5 3 5 5 6 5...
output:
? 7 1 2 3 4 5 6 7 ? 6 1 8 9 10 11 12 ? 7 2 3 4 5 8 9 10 ? 4 2 3 8 11 ? 3 2 9 11 ? 4 2 4 8 12 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 6 16 17 18 20 21 22 ? 8 13 16 17 19 20 21 23 24 ? 6 14 15 16 19 20 21 ? 2 16 23 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 7 25 28 29 32 33 ...
result:
ok Sequence is guessed#op = 47847, #bit = 284607
Test #14:
score: 0
Accepted
time: 387ms
memory: 8400kb
input:
100000 3 7 6 1 2 4 5 3 3 5 4 5 7 5 3 2 3 6 4 5 1 2 3 3 2 3 3 4 4 5 4 5 4 3 2 5 5 2 3 1 2 6 4 0 5 3 5 3 1 1 5 1 1 6 5 3 5 2 4 5 4 5 1 2 4 4 4 3 1 1 3 2 2 2 1 0 3 4 4 3 4 4 5 3 4 3 1 0 6 5 3 3 1 3 4 2 1 3 0 3 4 4 5 4 1 5 7 3 1 1 5 6 7 4 3 1 3 4 3 1 2 2 4 6 3 1 2 4 6 6 4 3 1 3 5 3 3 3 2 6 5 4 3 1 1 3 6...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 8 1 4 5 6 8 9 10 11 ? 2 2 4 ? 2 2 5 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 6 16 17 18 20 21 22 ? 6 13 14 16 19 20 21 ? 6 13 15 17 19 20 22 ? 4 14 17 20 23 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 6 28 29 30 32 33 34 ? 5 25 28 3...
result:
ok Sequence is guessed#op = 47799, #bit = 283843
Test #15:
score: 0
Accepted
time: 374ms
memory: 8468kb
input:
100000 3 2 3 3 1 3 1 2 2 2 4 4 4 3 2 4 4 6 5 2 2 2 6 4 5 5 1 0 2 4 3 4 0 0 2 5 6 2 0 5 4 5 4 0 0 1 3 3 1 1 1 2 3 5 2 4 5 5 5 2 2 2 4 4 3 5 1 1 5 2 5 1 2 5 4 6 2 4 1 0 3 4 2 3 2 1 4 4 3 5 2 2 3 3 2 5 1 0 3 2 5 1 1 2 2 4 4 2 4 1 2 1 1 2 0 4 7 5 1 4 5 4 5 3 4 0 4 3 3 2 3 1 4 4 3 5 2 2 4 4 5 3 2 2 5 5 6...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 8 4 5 6 8 9 10 11 12 ? 4 1 4 8 9 ? 2 5 8 ? 7 9 13 14 15 16 17 18 ? 8 9 13 14 19 20 21 22 23 ? 7 15 16 17 19 20 21 22 ? 5 9 15 16 18 23 ? 3 9 13 17 ? 7 16 24 25 26 27 28 29 ? 8 16 24 25 30 31 32 33 34 ? 7 26 27 28 30 31 32 33 ? 6 16 26 29 30 31 34 ? 6 24 27 ...
result:
ok Sequence is guessed#op = 47807, #bit = 284074
Test #16:
score: 0
Accepted
time: 363ms
memory: 8440kb
input:
100000 3 4 4 3 2 1 3 6 5 6 1 5 4 6 3 4 4 1 3 3 1 2 1 2 3 3 3 2 3 3 4 3 2 3 4 3 2 3 1 0 4 6 6 2 0 3 3 1 3 1 3 4 3 3 5 1 0 4 3 3 3 2 1 4 4 5 3 2 1 2 4 6 6 3 5 2 6 2 5 1 6 3 5 6 2 3 3 4 5 2 0 4 6 6 3 3 2 5 4 6 4 1 1 4 3 4 2 1 4 3 5 3 2 2 2 4 3 3 1 1 0 4 6 4 1 3 2 0 1 1 3 4 3 1 2 3 3 4 4 4 4 2 4 4 5 3 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 7 1 2 4 7 8 9 10 ? 5 3 5 7 8 9 ? 4 1 6 8 10 ? 7 9 13 14 15 16 17 18 ? 8 9 13 14 19 20 21 22 23 ? 7 9 15 16 19 20 21 22 ? 8 13 15 17 18 19 20 21 22 ? 4 14 15 17 23 ? 7 23 24 25 26 27 28 29 ? 8 23 24 25 30 31 32 33 34 ? 9 23 26 27 28 29 30...
result:
ok Sequence is guessed#op = 47818, #bit = 284201
Test #17:
score: 0
Accepted
time: 355ms
memory: 8376kb
input:
100000 5 4 6 0 2 1 3 2 1 3 4 4 2 1 1 5 6 6 3 1 2 3 2 5 1 1 2 2 4 3 2 3 2 4 4 3 5 2 2 4 6 4 2 2 1 5 7 5 5 0 2 1 2 0 2 5 5 2 1 5 6 5 3 2 1 2 2 2 2 1 3 3 3 3 3 1 1 2 2 4 1 1 1 4 5 2 3 1 4 2 2 2 3 4 4 3 5 2 1 1 3 3 3 1 3 3 1 2 4 1 7 2 1 1 0 2 4 4 2 3 0 4 4 4 3 5 2 4 4 5 3 4 2 3 5 3 2 1 2 3 4 2 1 0 6 4 6...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 2 4 8 9 12 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 6 16 17 18 20 21 22 ? 3 16 17 20 ? 3 16 18 20 ? 7 22 25 26 27 28 29 30 ? 8 22 25 26 31 32 33 34 35 ? 7 27 28 29 31 32 33 34 ? 7 22 25 27 30 31 32 33 ? 4 26 27 28 31 ...
result:
ok Sequence is guessed#op = 47965, #bit = 284748
Test #18:
score: 0
Accepted
time: 394ms
memory: 8520kb
input:
100000 2 4 4 1 3 0 4 4 3 4 2 2 3 3 4 2 1 1 3 5 2 3 2 3 4 3 3 4 1 5 6 7 3 3 2 3 3 3 3 3 1 5 3 3 3 1 2 4 5 1 0 5 4 4 1 0 3 0 2 2 4 3 2 4 0 4 6 4 0 5 4 6 2 3 1 2 3 3 3 1 2 6 3 6 1 0 5 6 7 3 3 1 4 7 5 3 1 4 6 6 3 2 2 3 0 4 5 5 5 6 0 6 4 6 2 0 2 5 5 3 4 1 2 4 3 3 0 2 5 6 2 0 5 8 2 3 2 4 1 2 1 4 4 5 3 2 0...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 1 4 5 8 12 ? 3 2 6 8 ? 1 9 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 7 16 17 18 20 21 22 23 ? 7 13 14 16 19 20 21 22 ? 5 15 17 19 20 21 ? 6 13 15 16 19 22 23 ? 7 21 25 26 27 28 29 30 ? 8 21 25 26 31 32 33 34 35 ? 6 27 ...
result:
ok Sequence is guessed#op = 47938, #bit = 284548
Test #19:
score: 0
Accepted
time: 370ms
memory: 8664kb
input:
100000 1 3 2 3 1 0 7 2 1 2 4 6 6 3 3 2 4 5 4 3 1 2 1 2 2 3 5 5 5 2 3 3 5 2 1 0 4 4 4 3 3 6 3 2 4 1 2 1 3 4 5 2 3 2 2 4 3 2 1 3 4 4 5 3 0 4 6 7 1 2 3 3 4 3 3 1 3 5 4 4 3 1 4 5 4 6 5 1 2 4 4 4 0 3 3 0 2 1 3 5 4 3 4 0 2 5 6 2 0 2 5 4 4 5 3 5 4 4 3 1 4 2 2 3 0 0 3 3 3 3 2 2 0 3 6 3 1 1 1 5 5 5 4 4 3 6 4...
output:
? 7 1 2 3 4 5 6 7 ? 6 1 8 9 10 11 12 ? 7 2 3 4 5 8 9 10 ? 7 2 3 4 5 8 11 12 ? 2 2 9 ? 3 2 3 10 ? 7 5 13 14 15 16 17 18 ? 5 19 20 21 22 23 ? 2 19 20 ? 2 19 21 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 8 27 28 29 31 32 33 34 35 ? 5 24 25 27 31 32 ? 5 24 26 27 33 34 ? 4 25 26 31 32 ? 7 32 ...
result:
ok Sequence is guessed#op = 47940, #bit = 284752
Test #20:
score: 0
Accepted
time: 389ms
memory: 8440kb
input:
100000 7 4 2 0 2 2 4 2 0 1 2 0 1 1 3 3 4 2 0 2 3 3 0 3 0 4 6 6 4 3 1 3 3 4 3 3 2 4 6 6 4 5 1 2 2 2 2 1 3 0 2 5 3 1 2 4 5 2 4 2 1 5 5 5 2 1 2 3 3 5 4 0 2 3 2 3 1 2 2 4 2 1 1 2 3 2 4 0 4 4 4 4 6 0 2 2 3 2 3 3 4 3 4 4 3 3 4 2 0 1 0 4 4 2 1 0 4 6 5 4 2 4 4 5 2 4 2 1 2 3 0 5 3 3 4 4 6 6 4 4 1 1 3 3 3 3 4...
output:
? 7 1 2 3 4 5 6 7 ? 5 8 9 10 11 12 ? 2 8 9 ? 1 10 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 4 16 17 20 21 ? 4 16 18 20 22 ? 7 25 26 27 28 29 30 31 ? 6 25 32 33 34 35 36 ? 6 26 27 28 29 32 33 ? 3 30 34 35 ? 2 25 34 ? 7 36 37 38 39 40 41 42 ? 8 36 37 38 43 4...
result:
ok Sequence is guessed#op = 47701, #bit = 283056
Test #21:
score: 0
Accepted
time: 406ms
memory: 8372kb
input:
100000 5 6 7 4 6 4 2 3 1 0 4 6 4 1 1 1 3 5 4 5 3 1 3 2 3 2 0 0 6 4 4 4 4 2 4 6 3 2 0 4 5 3 1 4 5 4 5 4 4 2 3 3 2 4 3 2 3 2 2 0 3 3 5 2 0 3 1 1 1 1 4 3 2 3 2 2 4 5 5 5 6 1 5 4 4 2 4 3 0 1 4 2 1 2 1 1 1 2 0 4 3 3 6 4 4 5 3 2 1 3 5 5 7 4 3 4 4 2 3 3 0 3 4 2 1 1 1 1 4 6 6 4 5 2 4 4 5 3 2 2 4 2 1 0 5 4 5...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 2 4 5 8 9 ? 6 2 3 6 7 8 9 ? 7 5 13 14 15 16 17 18 ? 8 5 13 14 19 20 21 22 23 ? 7 5 15 16 19 20 21 22 ? 6 5 17 18 19 20 23 ? 3 13 17 21 ? 7 22 24 25 26 27 28 29 ? 8 22 24 25 30 31 32 33 34 ? 8 26 27 28 30 31 32 33 34 ? 3 26 30 31 ? ...
result:
ok Sequence is guessed#op = 47848, #bit = 284720
Test #22:
score: 0
Accepted
time: 350ms
memory: 8464kb
input:
100000 4 3 3 4 2 2 5 5 7 4 5 0 5 4 5 3 4 1 5 6 5 3 3 4 6 7 2 1 6 2 3 2 2 0 3 3 3 1 4 0 4 3 5 2 3 5 6 7 3 3 1 5 4 7 3 2 4 6 5 2 1 3 2 2 1 0 0 4 6 5 2 2 2 3 3 2 2 5 6 2 3 3 1 0 3 4 2 1 1 1 2 3 6 4 2 2 2 5 4 3 0 3 4 2 2 1 3 5 5 4 2 1 0 2 4 4 3 2 0 3 4 3 1 4 1 4 5 2 5 2 2 5 5 6 3 5 0 5 5 6 2 2 2 4 4 4 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 7 2 4 5 7 8 11 12 ? 7 3 4 6 7 8 9 11 ? 2 1 4 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 6 14 16 17 18 20 24 ? 6 13 14 16 19 20 21 ? 2 16 22 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? ...
result:
ok Sequence is guessed#op = 47885, #bit = 284411
Test #23:
score: 0
Accepted
time: 376ms
memory: 8668kb
input:
100000 4 3 2 3 3 0 2 2 4 2 1 0 5 4 6 2 4 1 1 4 5 2 2 2 4 4 6 2 0 5 2 5 0 2 4 5 3 2 4 4 5 4 4 2 0 4 5 4 5 5 3 3 1 3 1 0 5 3 3 4 4 2 2 3 0 0 6 4 4 5 2 0 5 4 6 1 2 1 2 2 2 0 1 4 2 1 3 4 6 6 3 3 3 3 5 4 3 3 2 2 3 3 1 4 3 2 2 3 2 3 5 4 4 2 3 2 3 5 4 5 2 1 3 5 2 2 1 0 2 5 5 3 2 2 6 3 5 5 1 2 5 7 4 2 0 5 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 6 4 5 7 8 11 12 ? 4 2 3 4 8 ? 2 4 11 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 4 16 17 20 21 ? 4 16 18 20 22 ? 2 16 19 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 9 25 28 29 30 31 32 ...
result:
ok Sequence is guessed#op = 47815, #bit = 284735
Test #24:
score: 0
Accepted
time: 373ms
memory: 8520kb
input:
100000 3 6 6 1 3 4 5 6 0 0 5 6 5 3 2 2 4 3 3 4 4 2 4 5 3 2 3 2 4 5 6 1 1 5 3 4 4 1 3 2 3 1 2 1 0 5 4 5 4 2 2 2 3 4 2 1 1 3 6 5 4 3 3 4 2 2 2 0 4 5 3 2 4 2 4 3 2 0 3 3 2 3 2 0 4 3 4 3 5 3 2 4 4 1 2 0 5 7 3 1 1 5 5 5 5 2 1 5 5 5 4 5 2 6 6 0 5 3 4 2 2 3 4 4 5 1 1 1 2 3 3 1 1 1 1 3 2 1 0 2 4 5 2 3 3 3 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 8 9 10 11 ? 3 2 4 12 ? 3 5 6 12 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 6 16 17 18 20 21 22 ? 2 19 23 ? 1 13 ? 7 15 25 26 27 28 29 30 ? 8 15 25 26 31 32 33 34 35 ? 9 15 27 28 29 30 31 32 33 34 ? 4 27 28 31 32 ? 3 27 29 31 ? 2 29 32 ? ...
result:
ok Sequence is guessed#op = 47885, #bit = 284431
Test #25:
score: 0
Accepted
time: 372ms
memory: 8464kb
input:
100000 5 6 7 4 4 1 4 5 2 4 2 2 4 4 4 3 5 3 4 5 3 4 3 1 5 6 6 1 6 3 6 2 0 4 5 3 3 5 3 4 6 4 1 0 4 5 2 4 2 3 3 4 4 4 2 1 4 4 4 5 4 3 5 3 3 5 4 4 4 4 5 0 6 1 1 2 1 4 7 6 1 2 1 0 0 0 6 3 5 4 1 2 3 4 4 4 2 1 5 7 5 4 2 3 3 3 2 1 3 3 2 1 1 1 3 3 2 4 2 3 5 4 5 3 3 1 5 6 6 4 1 2 3 2 4 0 0 4 5 4 5 3 4 0 3 2 4...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 2 4 5 8 9 ? 6 2 3 6 7 8 9 ? 2 6 10 ? 7 11 13 14 15 16 17 18 ? 8 11 13 14 19 20 21 22 23 ? 6 15 16 17 19 20 21 ? 7 15 16 18 19 20 22 23 ? 4 11 13 17 19 ? 5 11 14 15 17 20 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 27 2...
result:
ok Sequence is guessed#op = 47784, #bit = 284187
Test #26:
score: 0
Accepted
time: 355ms
memory: 8460kb
input:
100000 4 4 1 2 6 2 4 4 3 4 5 2 2 1 1 4 5 4 7 0 4 3 3 4 4 3 3 5 4 5 4 2 4 4 6 1 0 3 5 5 3 0 2 2 4 2 3 0 6 5 3 5 1 1 6 3 5 4 2 1 3 5 3 5 5 0 4 5 2 3 2 2 5 5 5 4 2 1 3 4 4 5 2 1 3 3 3 0 2 4 3 2 2 2 2 5 5 4 2 6 3 5 4 2 1 4 5 3 4 3 1 5 3 4 4 2 4 6 4 1 1 1 3 1 1 1 0 4 2 3 3 3 1 5 5 6 2 3 3 2 2 4 2 2 1 0 5...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 2 7 8 ? 7 13 14 15 16 17 18 19 ? 6 13 20 21 22 23 24 ? 5 13 14 15 16 20 ? 5 14 17 18 20 21 ? 3 13 19 20 ? 7 16 25 26 27 28 29 30 ? 8 16 25 26 31 32 33 34 35 ? 6 27 28 29 31 32 33 ? 7 27 28 30 31 32 34 35 ? 3 29 31 34 ? 3 27 33 34 ? 7 36 ...
result:
ok Sequence is guessed#op = 47925, #bit = 284318
Test #27:
score: 0
Accepted
time: 366ms
memory: 8464kb
input:
100000 6 3 5 6 3 3 5 4 3 2 0 4 4 2 3 3 2 3 3 2 0 4 4 2 3 2 2 4 6 5 2 2 1 4 6 5 4 1 0 5 3 5 2 1 2 5 4 4 1 2 2 2 2 2 1 2 1 3 3 3 2 1 2 2 3 2 2 1 2 5 4 4 1 1 0 6 4 5 3 2 2 3 3 1 2 2 4 4 2 4 1 1 1 4 4 4 3 2 3 0 3 4 3 2 2 0 5 5 7 4 6 1 4 6 5 2 4 1 3 5 3 3 3 2 3 5 3 3 3 0 4 6 5 2 4 1 2 0 1 2 3 5 2 1 1 0 4...
output:
? 7 1 2 3 4 5 6 7 ? 6 1 8 9 10 11 12 ? 7 2 3 4 5 8 9 10 ? 7 2 3 4 5 8 11 12 ? 3 1 6 8 ? 7 12 13 14 15 16 17 18 ? 8 12 13 14 19 20 21 22 23 ? 7 12 15 16 17 19 20 21 ? 7 13 15 16 18 19 22 23 ? 7 14 15 17 18 19 20 22 ? 4 14 16 17 19 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 27 28 29 31 3...
result:
ok Sequence is guessed#op = 47942, #bit = 285104
Test #28:
score: 0
Accepted
time: 329ms
memory: 8736kb
input:
100000 3 5 4 3 3 2 4 6 5 2 3 3 2 2 3 0 1 3 3 4 3 1 3 1 4 5 4 5 1 2 6 4 5 3 2 4 6 7 2 1 4 4 5 3 2 1 3 4 6 5 3 5 1 0 2 4 3 1 1 2 6 4 6 1 0 4 3 4 2 1 1 2 0 3 1 3 2 2 1 0 2 2 3 2 1 0 4 6 5 4 1 2 4 5 3 4 2 1 4 5 2 3 5 2 6 4 1 1 6 6 3 1 3 2 3 2 2 0 4 2 1 3 2 3 2 0 0 5 5 6 3 6 2 2 1 1 2 0 2 3 4 3 3 2 1 2 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 7 2 4 5 7 8 11 12 ? 7 3 4 6 7 8 9 11 ? 5 1 3 5 8 12 ? 7 11 13 14 15 16 17 18 ? 8 11 13 14 19 20 21 22 23 ? 8 15 16 17 19 20 21 22 23 ? 4 11 15 19 20 ? 4 11 16 21 22 ? 3 13 16 19 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 9 24 ...
result:
ok Sequence is guessed#op = 47993, #bit = 284931
Test #29:
score: 0
Accepted
time: 330ms
memory: 8440kb
input:
100000 2 3 3 3 0 0 4 3 5 0 5 2 3 1 5 3 4 1 0 4 4 2 4 0 1 1 2 3 5 3 3 1 4 6 6 4 5 1 0 3 2 2 2 2 1 3 3 2 4 1 2 2 4 3 3 2 4 5 3 3 2 2 2 3 3 2 1 2 2 1 3 2 3 2 3 3 0 2 0 1 3 3 2 0 2 3 5 3 4 3 4 4 6 4 5 3 4 2 2 4 2 1 2 3 2 4 4 4 2 4 5 4 4 2 2 2 3 5 6 1 1 2 1 1 0 0 3 3 3 2 3 1 2 4 3 2 4 2 2 4 2 3 1 4 5 3 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 4 2 4 8 9 ? 2 4 10 ? 1 5 ? 7 7 13 14 15 16 17 18 ? 8 7 13 14 19 20 21 22 23 ? 7 7 15 16 17 19 20 21 ? 4 7 18 19 22 ? 7 14 24 25 26 27 28 29 ? 8 14 24 25 30 31 32 33 34 ? 9 14 26 27 28 29 30 31 32 33 ? 2 26 27 ? 7 27 35 36 37 38 39 40...
result:
ok Sequence is guessed#op = 47988, #bit = 285331
Test #30:
score: 0
Accepted
time: 370ms
memory: 8660kb
input:
100000 6 4 4 4 3 2 1 1 0 1 0 4 5 3 5 2 2 4 6 6 3 2 5 6 8 1 0 3 4 4 2 2 1 0 2 1 2 3 4 3 4 3 1 4 4 4 3 4 1 2 2 4 1 1 2 4 3 4 3 4 1 5 5 6 2 1 2 0 1 0 4 3 2 3 2 2 3 2 2 2 1 3 5 4 6 2 2 2 3 3 2 3 2 3 0 2 4 3 0 4 5 4 6 6 1 2 4 3 2 3 1 1 1 1 0 1 1 3 5 2 1 3 3 4 2 2 2 0 4 4 4 4 5 1 3 5 4 2 2 1 2 3 4 4 1 3 4...
output:
? 7 1 2 3 4 5 6 7 ? 6 1 8 9 10 11 12 ? 6 2 3 4 5 8 9 ? 6 2 3 6 7 8 10 ? 5 2 4 5 9 10 ? 3 3 4 9 ? 7 13 14 15 16 17 18 19 ? 6 13 20 21 22 23 24 ? 4 14 15 20 21 ? 3 13 16 22 ? 4 13 17 18 22 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 6 27 28 29 31 32 33 ? 6 24 25 27 30 31 32 ? 6 24 25 28 29 ...
result:
ok Sequence is guessed#op = 48011, #bit = 285470
Test #31:
score: 0
Accepted
time: 385ms
memory: 8408kb
input:
100000 4 3 5 2 4 2 2 6 5 2 1 3 2 4 1 2 1 3 4 6 2 1 3 5 4 2 1 0 4 5 3 4 4 1 5 3 4 3 2 0 5 3 5 3 0 3 3 2 1 2 2 2 3 2 2 0 2 3 4 3 2 1 2 3 4 3 4 3 4 5 3 3 4 3 3 4 4 3 3 4 2 4 3 4 4 3 1 0 3 1 1 0 3 2 2 1 2 1 5 5 6 1 0 5 6 6 2 3 2 2 4 3 4 1 2 3 2 3 1 3 0 5 5 7 4 6 2 4 2 1 2 1 2 2 2 3 1 3 5 2 2 2 1 2 3 1 0...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 4 1 7 8 11 ? 6 1 4 7 9 10 11 ? 3 4 9 11 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 3 14 16 24 ? 2 14 17 ? 7 19 25 26 27 28 29 30 ? 8 19 25 26 31 32 33 34 35 ? 8 27 28 29 31 32 33 34 35 ? 3 27 31 ...
result:
ok Sequence is guessed#op = 47837, #bit = 283983
Test #32:
score: 0
Accepted
time: 394ms
memory: 8456kb
input:
100000 4 6 6 5 1 0 1 4 1 1 1 0 2 5 4 2 3 1 2 1 1 3 3 6 5 3 1 4 3 2 2 1 1 4 3 2 3 3 0 2 5 5 1 1 4 3 3 3 2 2 3 4 3 4 2 1 4 4 3 5 2 3 4 6 4 1 1 1 3 2 2 2 2 0 1 4 1 1 1 1 2 4 3 4 1 1 3 6 3 1 2 0 5 6 7 4 3 1 5 6 6 3 2 0 0 2 2 2 4 4 3 1 2 3 2 4 3 3 2 2 2 1 2 2 4 4 2 1 0 5 5 6 2 4 0 5 5 7 2 1 5 5 5 2 1 1 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 8 4 5 6 8 9 10 11 12 ? 5 1 2 4 8 9 ? 2 5 10 ? 2 5 11 ? 7 13 14 15 16 17 18 19 ? 6 13 20 21 22 23 24 ? 5 13 14 15 16 20 ? 5 14 17 18 20 21 ? 3 13 19 20 ? 1 22 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 9 25 28 29 30 32 33 34 35 36 ? 5 26 31 32 33...
result:
ok Sequence is guessed#op = 47846, #bit = 283889
Test #33:
score: 0
Accepted
time: 399ms
memory: 8660kb
input:
100000 3 6 4 5 2 2 4 5 4 6 5 2 4 5 4 4 4 3 1 1 0 1 0 6 4 5 6 2 3 6 4 2 2 3 2 2 1 2 0 2 3 2 2 2 1 5 7 6 0 5 3 6 0 1 4 4 4 4 4 3 0 2 3 2 2 1 0 5 4 6 0 3 5 3 3 4 6 4 5 4 2 0 4 5 3 4 3 3 1 5 2 4 0 3 4 4 3 2 3 2 3 3 1 3 2 0 4 3 2 3 2 1 4 5 5 4 2 2 3 1 1 0 0 3 4 2 1 3 0 2 0 1 1 3 4 2 1 2 0 4 4 4 3 1 1 3 6...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 8 9 10 11 ? 6 1 6 7 8 9 12 ? 3 2 6 10 ? 2 1 2 ? 7 11 13 14 15 16 17 18 ? 8 11 13 14 19 20 21 22 23 ? 6 15 16 17 19 20 21 ? 8 11 15 16 18 19 20 22 23 ? 7 11 13 17 18 21 22 23 ? 2 17 19 ? 7 16 24 25 26 27 28 29 ? 8 16 24 25 30 31 32 33 34 ? 6 26 27 28...
result:
ok Sequence is guessed#op = 47771, #bit = 283247
Test #34:
score: 0
Accepted
time: 344ms
memory: 8464kb
input:
100000 3 5 4 6 5 4 5 4 1 2 2 3 3 4 2 5 6 2 0 1 4 1 0 5 7 5 5 0 3 5 4 3 5 2 3 3 3 2 3 2 3 1 3 2 0 3 4 2 0 2 5 1 0 3 2 4 2 2 1 4 5 2 3 2 2 3 4 3 4 3 1 2 4 3 3 3 2 4 3 3 3 4 1 2 4 3 5 4 5 3 3 6 6 2 3 3 1 1 4 3 2 4 0 4 3 4 3 4 2 3 3 3 3 2 5 3 4 3 2 2 2 2 5 3 4 3 4 2 4 3 2 1 4 3 1 0 0 3 3 4 2 1 1 5 4 7 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 7 2 4 5 7 8 11 12 ? 7 10 13 14 15 16 17 18 ? 8 10 13 14 19 20 21 22 23 ? 9 10 15 16 17 18 19 20 21 22 ? 5 10 15 16 19 23 ? 3 13 17 19 ? 3 13 18 20 ? 7 22 24 25 26 27 28 29 ? 8 22 24 25 30 31 32 33 34 ? 9 22 26 27 28 29 30 31 32 33 ? 4 24 ...
result:
ok Sequence is guessed#op = 47913, #bit = 284455
Test #35:
score: 0
Accepted
time: 374ms
memory: 8464kb
input:
100000 5 7 5 4 2 4 4 4 1 4 1 4 4 4 5 3 2 2 5 5 2 3 1 4 5 3 3 1 4 4 2 2 2 4 5 3 2 3 2 3 3 4 4 3 3 4 5 4 4 3 1 1 3 5 4 5 3 1 5 5 6 3 5 0 4 5 5 5 6 1 6 3 5 5 0 4 4 3 3 4 3 3 2 3 1 1 2 4 5 4 5 1 1 4 3 4 3 3 3 2 3 4 3 2 1 4 6 3 1 2 5 4 6 3 3 4 3 3 3 2 2 2 2 1 2 3 0 4 5 3 4 4 2 4 2 2 5 1 3 5 3 5 4 2 6 4 4...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 6 4 5 6 8 9 10 ? 5 1 4 7 11 12 ? 2 1 5 ? 7 3 13 14 15 16 17 18 ? 8 3 13 14 19 20 21 22 23 ? 7 15 16 17 19 20 21 22 ? 6 3 15 18 19 20 23 ? 5 3 13 16 17 19 ? 2 3 21 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 27 28 29 31 32 33 34 ? 6 24 27 30 31 ...
result:
ok Sequence is guessed#op = 47827, #bit = 283747
Test #36:
score: 0
Accepted
time: 378ms
memory: 8440kb
input:
100000 5 6 7 3 4 1 5 3 6 0 1 0 3 1 0 5 4 5 1 0 6 3 4 3 3 0 2 7 1 4 4 4 2 3 0 3 6 5 5 4 0 2 3 5 3 2 2 4 4 5 3 2 1 2 2 2 1 2 1 3 5 2 2 1 0 1 3 3 2 1 2 1 1 1 1 0 2 4 4 2 2 3 3 2 3 2 3 4 6 8 1 3 3 2 2 2 0 5 5 7 4 6 1 5 4 5 4 0 1 2 4 4 3 3 3 6 3 2 0 3 5 4 5 5 3 3 4 2 1 2 6 4 4 4 5 4 3 1 0 1 3 5 4 3 3 3 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 2 4 5 8 9 ? 5 2 6 7 8 10 ? 3 2 4 11 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 20 21 22 23 24 ? 2 20 21 ? 1 22 ? 7 24 25 26 27 28 29 30 ? 5 31 32 33 34 35 ? 2 31 32 ? 2 31 33 ? 7 36 37 38 39 40 41 42 ? 8 3...
result:
ok Sequence is guessed#op = 47786, #bit = 283980
Test #37:
score: 0
Accepted
time: 390ms
memory: 8392kb
input:
100000 4 3 6 2 1 4 1 0 4 4 3 3 3 5 5 3 4 3 1 0 3 4 2 0 2 2 3 4 3 3 2 3 4 4 5 2 1 3 6 5 6 1 4 3 5 3 1 1 2 3 1 3 4 2 0 0 5 6 8 2 3 3 5 4 5 4 0 1 1 2 1 2 2 2 1 1 2 5 4 5 3 6 0 2 3 4 3 3 1 4 4 5 2 5 0 4 4 4 2 1 2 5 6 5 2 2 1 1 2 1 1 1 2 5 6 8 0 2 3 3 2 1 2 3 4 5 3 1 1 3 3 3 2 2 3 2 2 2 3 0 0 2 3 4 3 3 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 2 1 8 ? 7 10 13 14 15 16 17 18 ? 6 10 19 20 21 22 23 ? 5 10 13 14 15 19 ? 5 13 16 17 19 20 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 27 28 29 31 32 33 34 ? 7 24 25 27 30 31 32 33 ? 6 24 27 28 31 32 35 ? 6 24 28 30 31 33 34 ...
result:
ok Sequence is guessed#op = 47885, #bit = 284429
Test #38:
score: 0
Accepted
time: 332ms
memory: 8436kb
input:
100000 4 3 4 3 3 2 2 3 3 1 2 3 4 3 4 6 2 4 3 2 2 1 1 4 3 4 5 3 2 4 4 2 4 0 0 4 3 3 4 2 2 4 3 3 2 2 4 5 3 4 2 2 2 5 4 5 4 1 0 3 2 4 2 2 1 3 4 2 2 4 1 3 4 5 3 4 5 4 3 1 2 3 3 3 2 3 3 3 3 3 1 4 2 4 4 4 5 4 3 5 3 4 2 6 2 4 3 2 1 4 6 6 4 5 2 3 1 3 2 2 5 5 5 4 4 2 4 4 3 3 5 3 3 3 2 2 3 2 5 5 5 4 4 3 3 5 4...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 6 8 9 10 ? 8 1 4 5 7 8 9 11 12 ? 7 2 4 6 7 8 10 11 ? 7 2 3 5 7 9 10 12 ? 7 9 13 14 15 16 17 18 ? 8 9 13 14 19 20 21 22 23 ? 9 9 15 16 17 18 19 20 21 22 ? 4 13 15 19 20 ? 8 13 14 15 16 17 19 21 22 ? 4 9 15 21 23 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 ...
result:
ok Sequence is guessed#op = 47941, #bit = 284852
Test #39:
score: 0
Accepted
time: 365ms
memory: 8372kb
input:
100000 3 4 2 0 0 3 4 4 2 1 2 1 3 3 3 0 3 2 3 1 1 0 3 5 3 3 3 1 5 4 4 2 2 0 4 4 3 5 1 3 4 7 6 2 0 2 4 4 1 1 1 1 4 2 2 2 3 2 2 2 0 2 2 6 5 2 1 3 3 0 0 3 5 3 3 2 2 1 3 3 1 1 0 5 6 5 2 2 2 1 2 2 3 2 2 1 6 3 5 5 0 3 1 1 0 1 5 5 4 2 1 2 4 3 4 3 3 1 2 5 6 2 2 1 3 4 3 3 2 3 3 5 3 4 1 0 2 1 1 0 2 2 4 4 2 3 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 4 1 7 8 9 ? 2 4 10 ? 7 6 13 14 15 16 17 18 ? 8 6 13 14 19 20 21 22 23 ? 7 15 16 17 19 20 21 22 ? 7 6 13 15 18 19 20 21 ? 4 14 15 16 19 ? 2 6 20 ? 7 24 25 26 27 28 29 30 ? 6 24 31 32 33 34 35 ? 7 25 26 27 28 31 32 33 ? 4 25 26 31 34 ? 2 2...
result:
ok Sequence is guessed#op = 47840, #bit = 284438
Test #40:
score: 0
Accepted
time: 333ms
memory: 8372kb
input:
100000 2 4 4 3 1 2 2 4 3 3 1 2 2 3 2 0 1 2 4 4 0 1 2 2 4 2 2 1 0 3 6 3 1 2 1 4 2 3 1 1 2 5 6 6 4 1 1 2 4 4 2 3 0 4 3 3 2 2 3 2 3 3 2 3 1 5 3 4 4 1 5 4 5 3 7 2 4 5 2 1 1 3 2 2 1 0 0 2 3 5 4 4 6 5 2 3 3 4 3 3 2 3 0 5 6 7 3 4 0 2 5 5 4 2 1 4 2 1 1 0 3 4 5 3 3 1 4 4 5 3 3 1 2 5 4 6 3 2 3 2 3 4 2 0 4 5 4...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 5 1 4 5 8 12 ? 4 6 7 8 9 ? 2 4 10 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 9 13 16 17 18 19 20 21 22 23 ? 5 14 16 20 21 24 ? 5 13 15 17 20 21 ? 3 18 20 22 ? 2 18 21 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ?...
result:
ok Sequence is guessed#op = 47958, #bit = 285032
Test #41:
score: 0
Accepted
time: 349ms
memory: 8464kb
input:
100000 2 5 5 4 2 3 7 6 0 4 3 2 1 2 3 6 3 2 1 2 5 4 4 0 4 2 3 3 3 1 6 2 3 3 3 4 5 4 4 2 1 1 2 2 4 2 0 3 4 4 4 5 2 4 4 4 4 6 0 4 5 4 4 3 2 0 5 3 3 2 3 1 2 2 1 2 0 3 4 4 2 1 2 6 1 1 2 1 3 5 2 2 4 4 3 3 2 2 5 2 1 1 2 2 4 6 3 1 1 1 4 4 3 5 1 3 0 3 2 0 5 6 6 2 3 3 3 4 3 1 2 2 4 4 5 2 3 3 4 6 3 1 1 2 4 2 4...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 8 9 10 11 12 ? 5 2 4 5 8 9 ? 2 4 10 ? 7 12 13 14 15 16 17 18 ? 8 12 13 14 19 20 21 22 23 ? 8 12 15 16 17 19 20 21 22 ? 2 13 15 ? 7 17 24 25 26 27 28 29 ? 8 17 24 25 30 31 32 33 34 ? 7 17 26 27 28 30 31 32 ? 6 26 27 29 30 33 34 ? 2 17 26 ? 7 35 36 ...
result:
ok Sequence is guessed#op = 47867, #bit = 284828
Test #42:
score: 0
Accepted
time: 408ms
memory: 8436kb
input:
100000 3 6 4 2 0 3 4 3 3 5 0 4 5 4 5 3 3 2 4 5 3 6 1 3 2 2 1 2 4 5 2 5 1 2 4 4 5 1 2 0 3 3 2 5 2 1 3 6 4 5 2 2 3 4 3 2 2 0 6 4 6 1 1 3 4 3 4 5 4 5 4 7 2 2 2 4 3 1 1 4 2 3 4 1 3 1 1 0 0 2 5 6 3 2 3 4 2 2 4 0 5 5 5 2 2 0 1 3 2 2 1 2 1 3 2 3 1 1 4 4 4 3 6 3 3 2 5 2 2 4 4 2 3 5 5 6 7 3 4 3 5 3 6 1 1 2 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 1 4 5 8 9 10 11 ? 6 1 6 7 8 9 12 ? 3 4 8 12 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 7 16 17 18 20 21 22 23 ? 6 13 16 19 20 21 24 ? 6 14 17 19 20 22 24 ? 2 14 18 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 6 28 29 30 32 33 34 ? 8 ...
result:
ok Sequence is guessed#op = 47917, #bit = 284562
Test #43:
score: 0
Accepted
time: 379ms
memory: 8488kb
input:
100000 5 3 4 4 1 7 2 1 0 4 4 4 3 3 6 3 5 4 3 4 2 5 5 5 3 2 1 3 4 3 3 3 2 4 2 2 4 2 3 5 4 4 5 4 5 5 5 3 3 2 3 3 4 3 2 4 1 4 2 1 1 0 4 4 4 5 2 0 3 4 5 2 3 1 0 2 4 2 3 0 2 4 3 3 1 2 0 4 5 5 4 2 2 5 6 6 1 4 5 4 4 4 1 3 5 5 4 1 3 3 7 6 0 1 0 0 0 1 1 1 0 2 4 5 3 3 4 2 3 5 4 3 4 3 3 5 4 3 2 2 3 3 3 2 2 3 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 8 9 10 11 12 ? 5 2 4 5 8 9 ? 3 1 7 8 ? 7 13 14 15 16 17 18 19 ? 5 20 21 22 23 24 ? 2 20 21 ? 2 20 22 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 27 28 29 31 32 33 34 ? 6 24 27 30 31 32 35 ? 6 25 28 30 31 33 35 ? 7 26 27 28 30 32 34 35...
result:
ok Sequence is guessed#op = 47811, #bit = 283795
Test #44:
score: 0
Accepted
time: 344ms
memory: 8396kb
input:
100000 5 7 4 2 1 2 4 4 3 2 0 4 3 3 4 4 3 6 2 4 3 1 4 3 4 3 4 5 1 4 2 2 2 3 1 0 0 0 3 4 5 4 3 4 4 2 3 5 3 3 2 3 3 3 2 2 3 0 2 4 4 4 5 2 0 4 3 2 4 2 1 2 2 2 1 0 3 3 5 2 1 4 5 4 5 2 3 4 3 2 2 3 2 4 4 2 0 2 4 3 4 0 0 3 5 4 4 4 3 3 4 4 4 4 2 4 6 6 4 4 1 0 3 3 5 2 0 4 4 6 4 4 6 6 4 3 1 5 5 6 2 2 2 3 5 4 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 6 4 5 6 8 9 10 ? 4 4 7 8 9 ? 2 5 8 ? 7 9 13 14 15 16 17 18 ? 8 9 13 14 19 20 21 22 23 ? 9 9 15 16 17 18 19 20 21 22 ? 5 9 15 16 19 23 ? 4 17 18 19 20 ? 2 17 21 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 24 27 28 29 31 32 33 ? 7 25 27 28 30 31 ...
result:
ok Sequence is guessed#op = 47841, #bit = 284985
Test #45:
score: 0
Accepted
time: 401ms
memory: 8712kb
input:
100000 3 3 3 3 3 4 4 2 4 3 3 6 6 1 2 6 4 5 6 1 3 4 4 4 2 2 2 3 4 5 3 2 2 3 4 3 1 3 1 5 3 4 2 3 0 2 3 3 1 2 0 3 2 3 1 2 0 4 4 5 4 2 3 3 2 4 4 2 2 3 3 1 2 2 1 4 5 2 3 3 1 4 5 5 5 6 1 1 1 0 0 2 2 5 5 3 3 3 2 6 4 2 3 4 5 5 5 6 0 4 5 4 5 5 4 2 3 3 2 1 2 1 2 1 0 2 3 1 0 3 5 4 4 5 2 1 1 0 1 0 3 6 6 0 1 2 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 6 4 5 6 8 9 10 ? 6 1 2 4 7 8 9 ? 6 1 3 5 7 8 10 ? 6 3 4 6 7 9 10 ? 7 10 13 14 15 16 17 18 ? 8 10 13 14 19 20 21 22 23 ? 7 10 15 16 19 20 21 22 ? 3 10 17 19 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 7 24 27 28 31 32 33 34 ? 3 25 27 35 ? 3 28 29 ...
result:
ok Sequence is guessed#op = 47916, #bit = 284340
Test #46:
score: 0
Accepted
time: 379ms
memory: 8456kb
input:
100000 4 5 3 5 5 3 3 3 3 4 2 1 5 1 1 4 3 5 3 2 1 6 5 2 1 3 3 4 5 2 3 5 2 3 1 4 5 3 2 3 2 4 6 6 4 2 3 4 4 3 4 4 3 3 3 1 4 1 2 2 2 2 2 0 2 4 4 0 2 2 6 5 1 0 4 4 4 4 4 1 3 5 3 5 3 3 5 4 4 2 3 5 3 5 6 0 3 2 2 1 0 1 1 3 3 4 2 0 5 7 3 2 1 6 3 4 2 2 3 3 6 5 5 4 1 2 3 4 3 3 1 1 1 1 2 1 3 4 3 5 2 0 3 4 5 1 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 6 4 5 6 8 9 10 ? 6 1 2 4 7 8 9 ? 6 1 2 5 6 7 11 ? 7 6 13 14 15 16 17 18 ? 8 6 13 14 19 20 21 22 23 ? 6 15 16 17 19 20 21 ? 6 6 13 15 18 19 20 ? 6 6 14 16 18 19 21 ? 3 6 16 20 ? 7 24 25 26 27 28 29 30 ? 6 24 31 32 33 34 35 ? 1 24 ? 2 31 32 ? 7 32 36 37 38 39...
result:
ok Sequence is guessed#op = 47872, #bit = 283970
Test #47:
score: 0
Accepted
time: 380ms
memory: 8456kb
input:
100000 2 2 4 2 2 1 2 3 3 2 4 2 3 4 3 4 5 4 3 4 4 5 2 3 0 3 4 4 4 5 2 4 4 4 4 3 2 3 3 3 1 3 1 4 3 2 2 2 4 4 4 4 1 2 1 1 2 2 2 3 4 3 3 1 5 4 6 1 2 1 3 4 2 2 3 3 2 4 4 2 1 2 0 4 2 0 2 2 3 1 1 2 4 5 4 6 3 3 3 3 2 3 2 4 4 2 3 3 2 6 5 3 3 2 5 6 5 2 2 1 0 5 6 5 2 1 1 3 4 0 3 4 3 3 5 0 4 3 5 2 3 6 5 4 1 3 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 4 4 5 8 9 ? 4 4 6 8 10 ? 3 4 7 8 ? 2 4 9 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 6 16 17 18 20 21 22 ? 8 13 16 17 19 20 21 23 24 ? 6 14 15 16 19 20 21 ? 5 14 16 17 22 23 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 3...
result:
ok Sequence is guessed#op = 47991, #bit = 284712
Test #48:
score: 0
Accepted
time: 357ms
memory: 8456kb
input:
100000 2 2 4 3 2 0 2 3 4 3 4 3 4 5 3 3 4 2 4 4 4 3 4 2 3 5 2 1 0 3 4 1 2 0 4 3 4 5 3 0 4 4 2 5 1 1 3 1 1 1 4 6 5 2 4 1 2 4 3 3 2 1 4 5 5 3 2 5 3 4 3 1 0 3 3 3 2 2 4 4 3 4 2 1 5 3 3 2 3 2 4 2 3 2 0 5 6 6 4 1 2 2 2 2 2 1 0 2 4 5 2 1 3 4 3 4 6 1 4 5 4 7 1 3 0 2 4 3 2 3 1 1 4 3 3 5 1 0 3 3 3 2 4 1 3 2 1...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 9 1 4 5 6 7 8 9 10 11 ? 4 4 5 8 9 ? 3 4 6 8 ? 2 6 9 ? 7 11 13 14 15 16 17 18 ? 8 11 13 14 19 20 21 22 23 ? 9 11 15 16 17 18 19 20 21 22 ? 6 15 16 17 19 20 23 ? 6 15 16 18 19 21 23 ? 3 15 20 21 ? 7 24 25 26 27 28 29 30 ? 8 24 25 26 31 32 33 34 35 ? 6 27 28 2...
result:
ok Sequence is guessed#op = 47913, #bit = 284772
Test #49:
score: 0
Accepted
time: 357ms
memory: 8464kb
input:
100000 4 4 3 4 3 2 2 6 4 5 5 1 1 3 4 5 2 3 1 0 4 3 1 1 2 6 2 3 2 1 1 4 3 4 3 4 4 4 5 4 4 3 3 2 4 3 4 1 1 3 5 4 4 2 5 3 5 3 1 1 5 5 7 4 3 2 4 3 3 3 0 3 3 2 4 3 2 1 2 3 3 3 0 0 7 5 5 4 6 3 1 1 2 0 1 0 2 3 5 3 2 0 5 4 5 4 2 2 3 6 6 2 0 6 2 4 4 1 4 6 5 2 4 0 2 4 3 4 2 6 3 5 6 2 2 3 3 1 2 2 3 5 3 4 2 6 3...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 7 1 2 4 7 8 9 10 ? 5 3 5 7 8 9 ? 4 1 6 8 10 ? 2 1 4 ? 7 13 14 15 16 17 18 19 ? 6 13 20 21 22 23 24 ? 6 14 15 16 17 20 21 ? 6 14 15 16 17 22 23 ? 3 18 20 22 ? 2 18 21 ? 7 25 26 27 28 29 30 31 ? 8 25 26 27 32 33 34 35 36 ? 7 28 29 30 32 33...
result:
ok Sequence is guessed#op = 47862, #bit = 284399
Test #50:
score: 0
Accepted
time: 361ms
memory: 8660kb
input:
100000 3 4 4 3 2 3 0 3 4 3 4 2 2 0 4 2 0 3 5 3 5 6 5 5 5 4 3 2 3 4 3 5 1 2 4 5 5 3 0 3 4 3 2 1 2 3 4 3 3 1 2 4 4 4 2 2 4 5 4 4 2 0 2 5 5 2 1 3 5 4 4 5 1 6 5 3 4 1 5 5 6 3 6 1 5 5 5 2 2 1 4 2 2 3 0 0 6 3 5 4 1 1 5 5 4 2 1 1 4 2 1 2 3 3 3 2 3 4 0 1 2 3 0 4 3 4 4 2 2 0 4 3 3 4 5 1 5 3 5 2 2 4 5 3 3 5 2...
output:
? 7 1 2 3 4 5 6 7 ? 8 1 2 3 8 9 10 11 12 ? 7 4 5 6 8 9 10 11 ? 7 1 2 4 7 8 9 10 ? 5 3 5 7 8 9 ? 4 1 6 8 10 ? 3 1 3 4 ? 7 13 14 15 16 17 18 19 ? 8 13 14 15 20 21 22 23 24 ? 7 16 17 18 20 21 22 23 ? 6 13 16 19 20 21 24 ? 5 13 17 19 22 24 ? 3 14 18 20 ? 7 23 25 26 27 28 29 30 ? 5 31 32 33 34 35 ? 2 31 ...
result:
ok Sequence is guessed#op = 47922, #bit = 284803