下面定义整型变量的是_____。
A: Dim num
B:
C: Dim num$
D: Dim num!
E: Dim num%
A: Dim num
B:
C: Dim num$
D: Dim num!
E: Dim num%
举一反三
- 下列变量名定义正确的是( )。 A: dim B: 1_s C: fac D: _num
- Function fun(ByVal num As Long) As Long Dim k As Long k = 1 num = Abs(num) Do While num k = k * (num Mod 10) num = num \ 10 Loop fun = k End Function Private Sub command1_click() Dim n As Long, r As Long n = Val(InputBox("请输入一个数:")) r = fun(n) Print r End Sub 程序运行后,单击命令按钮,输入1234,输出结果为:( )
- 中国大学MOOC: 在窗体上添加一个命令按钮Command1,然后编写如下事件过程:Private Sub Command1_Click() Dim num As Integer num = 1 Do Until num > 6 Print num; num = num + 2.4 LoopEnd Sub程序运行后,单击命令按钮,则窗体上显示的内容是( )。
- 下面哪个定义了一个整型变量x A: Dim x As Single B: Dim x As Integer
- 在窗体上画一个名称为Command1的命令按钮,然后编写如下事件过程Private Sub Command1____Click()Dim num As Integernum = 1Do Until num > 6num = num + 2LoopPrint num;End Sub程序运行后,单击命令按钮,则窗体上显示的内容是:____