[單項(xiàng)選擇題] 編寫如下事件過程: Private sub sub1 (ByVal x1 As String, y1 As String)Dim xt As S
2021-07-20
[單項(xiàng)選擇題] 編寫如下事件過程:
Private sub sub1 (ByVal x1 As String, y1 As String)
Dim xt As String
Dim i As Integer
i = Len(x1)
Do While i>= 1
xt = xt + Mid(x1, i, 1)
i=i-1
Loop
y1 = xt
End Sub
Private Sub Form Click()
Dim s1 As String, s2 As String
s1= "teacher"
sub1 s1, s2
Print s2
End Sub
程序運(yùn)行后,單擊窗體,則窗體上顯示的內(nèi)容是
A.rehcaet
B.tahreee
C.themee
D.eerthea
正確答案:A解析:[分析]: 可以看出,Sub1(ByVal x1 As String,y1 As String)的作用是將參數(shù)x1的字符逆序處理,然后賦給y1,而y1是傳址引用的,可以直接返回處理結(jié)果。
詞條內(nèi)容僅供參考,如果您需要解決具體問題
(尤其在法律、醫(yī)學(xué)等領(lǐng)域),建議您咨詢相關(guān)領(lǐng)域?qū)I(yè)人士。