uses
	sysutils;

var
	i: longint;
	l, r: int64;

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

begin
	randseed := 1991;

	for i := 19 to 60 do begin
		rewrite(output, inttostr(i));

		repeat
    		l := rand(random(18) + 1);
    		r := rand(random(18) + 1);
    	until l <= r;
		writeln(l, ' ', r);

		close(output);
	end;
	for i := 61 to 70 do begin
		rewrite(output, inttostr(i));

		repeat
    		l := rand(18);
    		r := rand(18);
    	until l <= r;
		writeln(l, ' ', r);

		close(output);
	end;
end.