写出下面程序的运行结果(10分)
1. Private Sub Command1_Click()
x = 0
n = InputBox("")
For i = 1 To n
For j = 1 To i
x = x + 1
Next j
Next i
Print x
End Sub
程序运行后,单击命令按钮,如果输入5,则在窗体上显示的内容是:
2.
Option base 1
Private sub subp(b() As Integer)
for i=1 to 4
b(i)=2*i
next i
End Function
Private Sub Command1_Click()
Dim a() as integer
a(1)=5
a(2)=6
a(3)=7
a(4)=8
subp a()
for i= 1 to 4
print a(i)
next i
End Sub1. 15 2. 2
4
6
8
2015年全国职称计算机考试教材(2007模 .. 定价:¥225 优惠价:¥213 更多书籍 | |
全国职称计算机考试速成过关系列套装:W .. 定价:¥133 优惠价:¥133.0 更多书籍 |