Private Sub Command1_Click()
Dim x As Double
Randomize
Select Case x Mod 2
Case 1
Label1.Caption = x是奇数
Case 0
Label1.Caption = x是偶数
End Select
End Sub
我写的,我太笨,哪里有问题,求解答
Private Sub Command1_Click()
Dim x As integer
Randomize
x = cint(92 * rnd + 8)
Select Case x Mod 2
Case 1
Label1.Caption = x & "是奇数"
Case 0
Label1.Caption = x & "是偶数"
End Select
End Sub
自己测试下吧应该没问题
Private Sub Command1_Click()
Dim x As integer
Randomize
x = cint(92 * rnd + 8)
Select Case x Mod 2
Case 1
Label1.Caption = x & "是奇数"
Case 0
Label1.Caption = x & "是偶数"
End Select
End Sub
自己测试下吧应该没问题