program LiczbaDzielnikow;uses CRT;var n,i,j:integer;begin clrscr; write('Podaj n: '); readln(n); j:=0; for i:=1 to n do if (n mod i)=0 then inc(j);writeln('Liczba ',n,' ma ',j,' dzielnikow');readln;end.
" Life is not a problem to be solved but a reality to be experienced! "
© Copyright 2013 - 2024 KUDO.TIPS - All rights reserved.
program LiczbaDzielnikow;
uses CRT;
var
n,i,j:integer;
begin
clrscr;
write('Podaj n: ');
readln(n);
j:=0;
for i:=1 to n do
if (n mod i)=0 then
inc(j);
writeln('Liczba ',n,' ma ',j,' dzielnikow');
readln;
end.