Câu trả lời:
program tim_so_nguyen;
uses crt;
var i,N:integer;
begin
clrscr;
write('nhap so nguyen:');
readln(N);
if N <= 2 then write(N,' khong phai la so nguyen to')
else
begin
i:=2;
while ( N mod i <> 0 ) do i:=i+1;
if i=N then write(N,' la so nguyen to')
else write(N,' khong phai la so nguyen to');
end;
readln;
end.