vb程序。。分别在文本框Text1、Text2、Text3中输入3个数,输出最大的数。

2025-02-24 20:17:49
推荐回答(3个)
回答1:

Dim a, b, c, s As Integer
a = Text2.Text
b = Text3.Text
c = Text4.Text

If a > b Then
s = a
If a > c Then
s = a
Else
s = c
End If

Else
s = b
If b > c Then
s = b
Else
s = c
End If
End If

Print s

回答2:

dim a as integer
a=val(text1.text)
if aif aprint a

回答3:

a = Val(Text1)
b = Val(Text2)
c = Val(Text3)
If a < b Then a = b
If a < c Then a = c
MsgBox a