下面的语句用Array函数为数组a的各元素赋整数值: a=Array(1,2,3,4,5,6,7,8,9) 对数组变量a的正确定义是
A: A) Dim a
B: B) Dim a As Integer
C: C) Dim a(9) As Integer
D: D) Dim a() As IntegEr
A: A) Dim a
B: B) Dim a As Integer
C: C) Dim a(9) As Integer
D: D) Dim a() As IntegEr
举一反三
- 以个哪个选项定义了10个整形数构成的数组,数组元素为Array(1)至Array(10)?( ) A: Dim Array(10) As Integer B: Dim Array(10) Integer C: Dim Array(1 to 10) As Integer D: Dim Array(1 to 10) Integer
- 以下定义数组或给数组元素赋值的语句中,正确的是( )。 A: Dim a As Variant a=array(1,2,3,4,5) B: Dim a(10)As Integer a=array(1,2,3,4,5) C: Dim a%(10) a(1)= "ABCDE" D: Dim a(10)As Integer a=array("ABCDE")
- 如下数组声明语句,哪一个正确 ( ) A: Dim a[3,4] as Integer B: Dim a(3,4) As Integer C: Dim a(3;4) as Integer D: Dim a(3:4) As Integer
- 下列数组声明语句,________是正确的。 A: Dim a(3, 4) As Integer B: Dim a(3, 4) As Single C: Dim a{3, 4} As Integer D: Dim a[3, 4] As Integer E: Dim a(3 4) As Integer F: Dim a[3:4] As Integer
- 下列数组声明语句中,不正确的是_________。 A: Dim a(9) As Single = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} B: Dim a() = {1, 2, 3, 4, 5, 6, 10} C: Dim a( ,) As Single = {{1, 2, 3, 4, 5}, {6, 7, 8, 9, 10}} D: Dim a() As Single = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} E: Dim n As Integer=10Dim a(n) As Single