var
	x1, y1, x2, y2, x3, y3, x4, y4: longint;
	i: longint;
begin
	for x1 := 1 to 3 do begin
		for y1 := 1 to 3 do begin
			for x2 := 1 to 3 do begin
				for y2 := 1 to 3 do begin
                	for x3 := 1 to 3 do begin
                		for y3 := 1 to 3 do begin
                			for x4 := 1 to 3 do begin
                				for y4 := 1 to 3 do begin
                					if ((x1 <> x2) or (y1 <> y2)) and ((x3 <> x4) or (y3 <> y4)) then begin
                						if random(5) <> 0 then continue;
                						writeln(x1, ' ', y1, ' ', x2, ' ', y2);
                						writeln(x3, ' ', y3, ' ', x4, ' ', y4);
                					end;
                				end;
                			end;
                		end;
                	end;
				end;
			end;
		end;
	end;

    writeln('0 0 0 0');
    writeln('0 0 0 0');
end.