1. Private Sub Command1_Click( )
x=Int(Rnd)+3
If x^2>8 Then y=x^2+1
If x^2=9 Then y=x^2-2
If x^2<8 Then y=x^3
Print “y=”;y
End Sub
2. Public Sub Swap(ByVal x As Integer, y As Integer)
Dim t As Integer
t=x: x=y: y=t
End Sub
Private Sub Command1_Click( )
Dim a As Integer ,b As Integer
a=30: b=20
Swap a ,b
Print “a=”; a ;”b=”; b
End Sub
1. y= 7
2. a= 30 b=30
2015年全國職稱計算機考試教材(2007模 .. 定價:¥225 優(yōu)惠價:¥213 更多書籍 | |
全國職稱計算機考試速成過關(guān)系列套裝:W .. 定價:¥133 優(yōu)惠價:¥133.0 更多書籍 |