为什么会出现语法错误?(已解决)
本帖最后由 32714107 于 2013-4-29 22:44 编辑Local $i, $n, $r
$n = InputBox("Input", "To what number do you want to add up?")
$r = 0
$i = 0
Do $i = $i + 1
$r = $r + $i
Until $i >= $n
MsgBox(0, "Output", "The sum from 1 to " & $n & " is " & $r) Local $i, $n, $r
$n = InputBox("Input", "To what number do you want to add up?")
$r = 0
$i = 0
Do
$i = $i + 1
$r = $r + $i
Until $i >= $n
MsgBox(0, "Output", "The sum from 1 to " & $n & " is " & $r) 回复 1# 32714107
请注意DO--until的用法格式~~ 谢谢annybaby 前辈!
页:
[1]