风车牧场是荷兰原产吗:懂VB和24点的快来!(4/5)

来源:百度文库 编辑:查人人中国名人网 时间:2024/04/29 06:44:43
form_load事件
open app.path & "\cc.txt" for output as #1
dim a%,b%,c%,d%,e%
for a=1 to 10
for b=a to 10
for c=b to 10
for d=c to 10
e=e+1
if e>=430 and e<=572 then
print #1,a," ",b," ",c," ",d
end if
next
next
next
next
close #1
'然后打开cc.txt用+-*/^(乘方)V(log)算24
'格式:数1 数2 数3 数4 方法/无解

看不出你在问什么哦,
但是代码太不规范.
dim a, b, c, d, e as Integer
Private Sub form_load()
open app.path & "\cc.txt" for output as #1
for a=1 to 10
for b=a to 10
for c=b to 10
for d=c to 10
e=e+1
if e>=430 and e<=572 then
print #1,a," ",b," ",c," ",d
end if
next a
next b
next c
next d
close #1
End Sub