function rand(x: int64): int64;
var
	r: int64;
	i: longint;
begin
	r := 0;
	for i := 1 to 1000 do begin
		r := (r * 2 + random(2)) mod x;
	end;
	rand := r + 1;
end;

const
	maxn = 50;

var
	n: longint;
	maxc: int64;
	i: longint;
	a: array [1..maxn] of int64;

begin
	randseed := 130740274;

	n := 20;
	maxc := 1000000000;

	for i := 1 to n do begin
		a[i] := rand(maxc);
	end;

	writeln(n);
	for i := 1 to n do begin
		write(a[i]);
		if (i < n) then
			write(' ');
	end;
	writeln;
end.