mt19937_64 rnd(time(0));
signed main()
{
freopen("data.in","w",stdout);
int n=1e5,m=1e5,k=1e5;
cout<<15<<"\n"<<n<<" "<<m<<" "<<k<<endl;
For(i,2,n)cout<<i/2<<' '; // 可以改随机树
cout<<"\n";
For(i,1,m)cout<<rnd()%10000+1<<" "<<(i+1)/2<<endl;
For(i,1,m)cout<<1<<" "<<rnd()%100000+1<<" "<<(i+1+m)/2<<endl;
return 0;
}
mt19937_64 rnd(time(0));
int R(int l,int r){
return rnd()%(r-l+1)+l;
}
signed main()
{
freopen("data2.in","w",stdout);
int n=1e5,m=1e5,k=1e5;
cout<<15<<"\n"<<n<<" "<<m<<" "<<k<<endl;
int V=10000;
For(i,2,V)cout<<i-1<<" ";
For(i,V+1,n){
int t=i-V; t/=2;
cout<<V+t<<" ";
}
cout<<"\n";
For(i,1,m)cout<<rnd()%V+1<<" "<<(i+1)/2<<endl;
For(i,1,m)cout<<1<<" "<<rnd()%100000+1<<" "<<(i+1+m)/2<<endl;
return 0;
}