设有Function过程:Private Function f(a As Integer, b As Integer) As Integera = a * a:b

14 查阅

设有Function过程:

Private Function f(a As Integer, b As Integer) As Integer

a = a * a:

b = b * b

f = CInt(Sqr(a - b))

End Function

则如下程序段的运行结果是( )。

Private Sub Command1_Click()

Dim X As Integer, Y As Integer

X = 5: Y = 4

a = f(X, Y)

Print a

End Sub

A. 5

B. 4

C. 3

D. 9

参考答案:

C

计算机二级