王帅阿里巴巴身价:请问大家谁可以把VB的这段代码简化?

来源:百度文库 编辑:高校问答 时间:2024/04/29 06:22:54
拜托写上注释谢谢!

dim a as integer
for a=1 to 100
if a mod 3 = 0 then
print a
end if
next

这已经够简化了啊!是一个打印出1--100中能被3整除的数.
dim a as integer 定义a为整型
for a=1 to 100
if a mod 3 = 0 then 如果被3整除,则输出.
print a
end if
next