单击form1的”产生数据”按钮产生10个1到100的整数并在”原始数据”旁的文本框中显示
1个回答
展开全部
Dim x As Integer
Private Sub Command1_Click()
Randomize
Dim a(20) As Integer
For i = 1 To 20
a(i) = Int(Rnd * 100)
Text1 = Text1 " " a(i)
If x < a(i) Then x = a(i)
Next i
End Sub
Private Sub Command2_Click()
Text2 = x
End Sub
Private Sub Command1_Click()
Randomize
Dim a(20) As Integer
For i = 1 To 20
a(i) = Int(Rnd * 100)
Text1 = Text1 " " a(i)
If x < a(i) Then x = a(i)
Next i
End Sub
Private Sub Command2_Click()
Text2 = x
End Sub
本回答被网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询