单选题
VB
题号 #2536389
执行下列程序段
a$="Visual Basic Programmi ng"
b$="C++"
c$=UCase(Left$(a$,7))&b$&Right$(a$,12)
后,变量c$的值为( )。
参考答案
B
答案解析
Left$(字符串,个数)函数用于取出已有字符串最左边指定个数的字符串;Right(字符串,个数)函数用于取出已有字符串最右边指定个数的字符串;UCase()函数用于将字符串中小写字母转化为大写字母,原本大写或非字母字符保持不变;&运算符用来强制两个表达式作字符串连接。本题中UCase(Left$(a$,7))=UCase("Visual")="
VISU AL,Right$(a$,12)="Programmi ng",故答案为选项B。
VISU AL,Right$(a$,12)="Programmi ng",故答案为选项B。
你可能感兴趣的试题
A.MsgBox 语句的返回值是一个整数
B.执行MsgBox 语句并出现信息框后,不用关闭信息框即可执行其他操作
C.MsgBox 语句的第一个参数不能省略
D.如果省略MsgBox 语句的第三个参数(Title),则信息框的标题为空
A.Private Sub Text1_Change()
Label1.Caption =Str(Len(Text1.Text))
End Sub
Label1.Caption =Str(Len(Text1.Text))
End Sub
B.Private Sub Text1_Click()
Label1.Caption =str(Len(Text1.Text))
End Sub
Label1.Caption =str(Len(Text1.Text))
End Sub
C.Private Sub Text1_Change()
Labe11.Caption =Text1.Text
End Sub
Labe11.Caption =Text1.Text
End Sub
D.Private Sub Label l_Change()
Label1.Caption =Str(Len(Text1.Text))
End Sub
Label1.Caption =Str(Len(Text1.Text))
End Sub
A.Option1.Value =False
Check1.Value =True
Check1.Value =True
B.Optionl .Value =True
Checkl .Value =0
Checkl .Value =0
C.Option2.Value =False
Check1.Value =2
Check1.Value =2
D.Optionl .Value =True
Checkl .Value =1
Checkl .Value =1
