Program NhatNgu;
Uses crt;
Var a,i: longint;
Function ngto(a: longint): boolean;
Var i: longint;
Begin
If a<2 then exit(false);
For i:=2 to trunc(sqrt(a)) do
If a mod i = 0 then exit(false);
exit(true);
End;
Begin
Clrscr;
Write('Nhap a: '); Readln(a);
For i:=1 to a div 2 do
If (ngto(i)) and (ngto(a-i)) then Writeln(i,' ',a-i);
Readln
End.