填空题

标准模块和窗体模块的功能是计算和打印两个复数之和,在横线上填上适当内容。标准模块______。
Type comp
re As Single
im As Single
End Type
Public C As comp
窗体模块
Private Sub Commandl_Click()
Dim a As comp,b As comp
a.re=InputBox(“输入a的实部”)
a.im=InputBox(“输入a的虚部”)
b.re=InputBox(“输入b的实部”)
b.im=InputBox(“输入b的虚部”)
______
Print "c"="; c.re; "+"; c.im; "i"
End Sub
Private Sub s(______)
c.re = r1.re + r2.re
c.im = r1.im + r2.im
End Sub

【参考答案】

Call s(a,b) 或 s a,b
rA As comp,rB As comp 或 ByRef rA As ......

(↓↓↓ 点击下方‘点击查看答案’看完整答案、解析 ↓↓↓)