var m,n,i,d:longint;
function checkprime(x:longint):boolean;
var c:longint;
begin
if x<2 then exit(false);
for c:=2 to trunc(sqrt(x)) do if x mod c = 0 then exit(false) else exit(true);
end;
begin
write('Nhap m: '); readln(m);
write('Nhap n: '); readln(n);
for i:=m to n do if checkprime(i) then inc(d);
write('Tu ',m,' den ',n,' co ',d,' so nguyen to);
readln;
end.