#include<iostream>
#include<cstdio>
#include<algorithm>
#include<cstring>
#include<random>
using namespace std;
typedef unsigned long long ull;
random_device seed;
mt19937 rnd(seed());
int range(int l,int r){return rnd()%(r-l+1)+l;}
ull ullrand(){return ((ull)rnd()<<32)|rnd();}
int main()
{
	freopen("noodle.in","w",stdout);
	printf("3 1 %llu\n",ullrand());
	int n=128,q=500,k=500;
	printf("%d %d %d %d\n",n,q,range(1,n),k);
	for(int i=1;i<=n;i++) printf("%d ",range(1,1000));
	puts("");
	return 0;
}
