level 1
不要用很高级的语言,因为我是初学者,谢谢。
1+2
+3
+......+n 键入n,直接得出结果
分别用while和for next语句写
2009年10月31日 13点10分
1
level 4
cls
input "n ="n
for i = 1 to n
a = a + i
next i
print a
end
cls
input "n ="n
while a<=n
m = m + a
wend
print m
end
2009年11月09日 03点11分
2
level 2
while:
dim ctr,sum,n as integer
input "please input [n]";n
do while ctr<=n
ctr=ctr+1
sum=sum+ctr
loop
print sum
end
for next:
dim ctr,sum,n as integer
input "please input [n]";n
for ctr=1 to n step 1
sum=sum+ctr
ctr=ctr+1
next ctr
print sum
end
2010年03月29日 13点03分
4