单选题:在窗体上画一个名称为Text1的文本框,一个名称为Command1的命令按钮,然后编写如下事件过程和通用过程:Priva

  • 题目分类:VB
  • 题目类型:单选题
  • 号外号外:注册会员即送体验阅读点!
题目内容:
在窗体上画一个名称为Text1的文本框,一个名称为Command1的命令按钮,然后编写如下事件过程和通用过程:
Private Sub Command1_Click()
 n = Val(Text1.Text)
 If n\2 = n/2 Then
 f = f1(n)
Else
 f = f2(n)
End If
Print f; n
End Sub
Public Function f1(ByRef x)
x=x*x
f1=x+x
End Function
Public Function f2(ByVal x)
x=x*x
f2=x+x+x
End Function
程序运行后,在文本框中输入6,然后单击命令按钮,窗体上显示的是(  )。 A.72 36
B.108 36
C.72 6
D.108 6
参考答案:
答案解析:

依次填入下面一段文字横线处的语句,衔接最恰当的一组是:庐山瀑布群是有历史的,_______。庐山瀑布群便是以不同的风貌向

依次填入下面一段文字横线处的语句,衔接最恰当的一组是:庐山瀑布群是有历史的,_______。庐山瀑布群便是以不同的风貌向世人展示她的万般风情的。①赞颂其壮观雄

查看答案

在窗体上画一个名称为Text1的文本框和一个名称为Command1的命令按钮,然后编写如下事件过程Private Sub

在窗体上画一个名称为Text1的文本框和一个名称为Command1的命令按钮,然后编写如下事件过程Private Sub Command1_Click()Te

查看答案

According to the writer, one of the purposes of teaching Eng

According to the writer, one of the purposes of teaching English is to get stude

查看答案

Thousands of Irish people starved during the “Potato Famine”

Thousands of Irish people starved during the “Potato Famine” becauseA.they were

查看答案

Another important way to prolong the life of cut flowers is

Another important way to prolong the life of cut flowers is ____________________

查看答案