free pascal的大神们来看一下哪里错了,在线等!!!!!!!

2024-12-19 09:56:32
推荐回答(1个)
回答1:

var
a,b,c,d,e:integer;
begin
for a:=0 to 9 do
for b:=0 to 9 do
for c:=0 to 9 do
for d:=0 to 9 do
for e:=0 to 9 do
if ((a*10000+b*1000+c*100+d*10+e) mod 3=0)and((a*10000+b*1000+c*100+d*10+e) mod 7=0)and((a*10000+b*1000+c*100+d*10+e) mod 5=0)and((a*10000+b*1000+c*100+d*10+e) mod 13=0)
then writeln(a,b,c,e,d);

end.