下述代码A和B正确的值是() Dim X As String = "123" Dim Y As Integer = 123 Dim A As String = X + Y Dim B As String = X & Y
第1题:
没有如下的用户定义类型:
Type Student
number As String
name As String
age AS Integer
End Type
则以下正确引用该类型成员的代码是( )。 A.Student. name="李明"
B.Dim s As Student
S. name="李明"
C.Dim s As Type Student
S. name="李明"
D.Dim s As Type
S. name="李明
第2题:
下面可以正确定义两个整型变量和—个字符串变量的语句是______。
A.Dim n,m As Integer,s As String
B.Dim a%,b$,c As String
C.Dim a As Integer,b,c As String
D.Dim x%,y As Integer,z As String
第3题:
下面可以正确定义2个整形变量和1个字符串变量的语句的是( )。
A.Dim n,m AS Interger,s AS String
B.Dim a%,b$,c AS String
C.Dim a AS Integer,b,c AS String
D.Dim x%,y AS Integer,z AS String
第4题:
(23)下列程序执行后,变量x的值为 。 Dim a,b,c,d As Single Dim x As Single a=10 b=30 c=400 If b>a Then d=a:a=b:b=d End If If b>c Then x=b Elself a>c Then x=c Else x=c End IfA.10 B.30 C.400 D.430
第5题:
定义变量如下: Dim Str_x Str_x="祝你成功!" 若在立即窗口中显示Str_x的值,下面正确的是______。
A.Debug. Print Str_x
B.PictureBox. Print Str_x
C.Printer. Print Str_x
D.Print Str_x
第6题:
( 14 )设有如下的用户定义类型:
Type Student
number As String
name As String
age As Integer
End Type
则以下正确引用该类型成员的代码是
A ) Student.name = " 李明 "
B ) Dim s As Student
s.name = " 李明 "
C ) Dim s As Type Student
s.name = " 李明 "
D ) Dim s As Type
s.name = " 李明 "
第7题:
( 11 )下面可以正确定义 2 个整形变量和 1 个字符串变量的语句的是( )
A ) Dim n,m AS Interger,s AS String
B ) Dim a%,b$,c AS String
C ) Dim a AS Integer,b,c AS String
D ) Dim x%,y AS Integer,z AS String
第8题:
下面程序段运行后,变量x的值为上 【 】 。
Dim x As Integer
Dim i As Integer
x=O
for i=0 to 50 step 10
X=X+i
next i
第9题:
单击命令按钮时,下列程序代码的执行结果为( )。 Private Function FirProc(x As Integer,y As Integer,z As Integer) FirProc=2*x+y+3*z End Funcfion Private Function SecProc(x As Integer,y As Integer,z As Integer) SecProc=FirProc(z,x,y)+x End Funcfion Private Sub Command1_Click() Dim a As Integer Dim b As Integer Dim c As Integer a=2 b=3 c=4 Printf SecProc(c,b,a) End Sub
A.21
B.19
C.17
D.34
第10题:
下面程序段运行后,变量X的值为【 】。
Dim x AS Integer
Dim I AS Integer
x=0
for I=0 to 50 step 10
X=X+I。
next I
Print X