> 其他 >
VF编程计算所有四位数中能同时被9和11整除的数之和.怎么编?
人气:396 ℃ 时间:2020-01-30 13:30:42
解答
clear
s=0
for i=1000 to 9999
if i%9=0 and i%11=0或 if mod(i,9)=0 and mod(i,11)=0
s=s+i
endif
endfor
?"所有四位数中能同时被9和11整除的数之和:",s
return
推荐
猜你喜欢
© 2026 79432.Com All Rights Reserved.
电脑版|手机版