网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
单击命令按钮时,下列程序的运行结果为 Private Sub Command1_Click() Print Fun(23,18) End Sub Public Function Fun(m As Integer,n As Integer)As Integer Do While m<>n Do While m>n:m=m-n:Loop Do While m<n:n=n-m:Loop Loop Fun=m End Function
A.0
B.1
C.3
D.5
参考答案
更多 “ 单击命令按钮时,下列程序的运行结果为 Private Sub Command1_Click() Print Fun(23,18) End Sub Public Function Fun(m As Integer,n As Integer)As Integer Do While m<>n Do While m>n:m=m-n:Loop Do While m<n:n=n-m:Loop Loop Fun=m End FunctionA.0B.1C.3D.5 ” 相关考题
考题
单击命令按钮时,下列程序的运行结果为Private Sub Command1_Click()Print Fun(23,18)End SubPublic Function Fun(m As Integer,n As Integer) As IntegerDO While m<>nDO While m>n:m=m-n:LoopDO While m<n:n=n-m:LoopLoopFun=mEnd FunctionA.0B.1C.3D.5
考题
(25)下列程序的运行结果是 。 Private Function myfun(m,n) Do While mn Do While mn:m=m-n:Loop Do While nm:n=n-m:Loop Loop myfun=m End Function Private Sub Command1_Click() Print myfun(9,8) End SubA.2 B.1 C.4 D.3
考题
在窗体中添加—个名称为Command1的命令按钮,然后编写如下事件代码: Private Sub Command1_Click() MsgBox f(24,18) End Sub Public Function f(m As Integer,n As Integer)As Integer Do while m<>n Do while m>n m=m-n Loop Do While m<n n=n-m Loop Loop f=m End Function 窗体打开并运行后,单击命令按扭,则消息框的输出结果是______。A.2B.4C.6D.8
考题
有如下程序,该程序的执行结果为______。 Dim k As Integer n=5 m=1 k=1 Do While k <= n m=m*2 k=k+1 Loop Print mA.1B.5C.32D.40
考题
下列程序的运行结果是( )。 Private Function myfun(m,n) Do while mn Do While mn:m=m-n:Loop Do Wllile nm:n=n-m:Loop Loop myfun=m End Function Private Sub Command1_Click( ) print myfun(9,8) End SubA.2B.1C.4D.3
考题
在窗体上画一个名称为Command1命令按钮,然后编写如下事件过程: Private Function fun1(n As Integer)As Integer Dim k As Integer If n = 1 Then k = 1 Else k = 1 + fun1(n - 1)* 2 End If fun1 = k End Function Private Sub Command1_Click () Dim m As Integer, x As Integer x = 4 m = fun1 (x) Print m End Sub 程序运行后,单击命令按钮,则窗体上显示的内容是A.4B.6C.9D.15
考题
下列程序的运行结果是 Private Sub Form_Click() Dim k As Integer n=5 m=1 k=1 Do m=m+2 k=k+1 Loop Until k>n Print m End SubA.1B.12C.11D.32
考题
单击命令按钮时,下列程序代码的运行结果为 Private Sub Command1_Click() Print MyFunc(20, 18) End Sub Public Function MyFunc(m As Integer, n As Integer)As Integer Do While m<>n Do While m>n:m=m-n:Loop Do Whle m<n:n=n-m:Loop Loop MyFunc=m End FunctionA.0B.2C.4D.6
考题
单击命令按钮时,下列程序的运行结果为Private Sub Command1_Click( ) Print MyBM(23,18)End SubPublic Function MyBM(m As Integer,n As Integer)As Integer Do While m n Do While m > n:m=m - n:Loop Do While m < n:n=n - m:Loop Loop MyBM=mEnd FunctionA.0B.1C.3D.5
考题
有如下的程序: Private Sub Command1_Click() Dim k As Integer,m As Integer Dim P As Integer k=4:m=1 P=Fun(k,m):Print P; P=Fun(k,m):Print P End Sub Private Function Fun(a As Integer,b As Integer) Static m As Integer,i As Integer in=5:i=2 i=i+m+1 m=i+a+b Fun=m\2 End Function 单击命令按钮后,输出结果为A.2 2B.4 4C.5 5D.6 6
考题
单击命令按钮时,下列程序代码的运行结果为 Private Sub Command1_Click() print MyFunc(20,18) End Sub Public Function MyFunc (m As Integer,n As Integer)As Integer Do While m n Do While m > n:m=m - n:Loop Do While m < n:n=n - m:Loop Loop MyFunc=m End FunCtionA.0B.2C.4D.6
考题
有如下函数: Function fun(a As Integer,n As Integer)As Integer Dim m AS Integer While a=n a=a-n:m=m+1 Wend Fun=m End Function 该函数的返回值是。 A.a乘以n的乘积 B.a加n的和 C.a减n的差 D.a除以n的商(不含小数部分)
考题
单击命令按钮后,下列程序代码的执行结果是______。Public Sub fun (a As Integer, b As Integer, c As Integer)Doa=b+ cn=n+1Loop While n > 3End SubPrivate Sub command1_ click()Dim m As Integer, n As Integer, i As IntegerFor i = 0 To 2: m = n + 1: Next iFor i = 1 To 2: Call fun (m, n, i): Next iFor i = 0 To 3Print m;Next iEnd Sub
考题
下面程序的运行结果是 ______ 。程序的功能是 _______ 。Public Function myfun(m,n)Do while m>nDo while m>n:m=m-n:LoopDo While n>m:n=n-m:LoopLoopMyfun=mEnd FunctionPrivate Sub Command1_Click()Print myfun(15,15)End Sub
考题
单击命令按钮时,下列程序的运行结果为 Private Sub Command1_Click( ) Print Fun(23, 18) End Sub Public Function Fun(m As Integer, n As Integer) As Integer Do Whilem <> n Do While m > n : m--m - n: Loop Do While m < n : n=n - m: Loop Loop Fun =m End FunctionA.0B.1C.3D.5
考题
单击命令按钮时,下列程序代码的执行结果为______ 。Public Function MyFune(m As Integer,n As Integer) As Integer Do While m<>n Do While m>n m=m-n Loop Do While m<n n=n -m Loop Loop MyFunc=mEnd FunctionPrivate Sub Command1_Click() Print MyFunc(24, 18)End SubA. 2B.4C.6D.8
考题
下列程序的运行结果是( )。 Private Function myfun(m,n) Do While m>n Do While m>n:m=m-n:Loop Do While n>m:n=n-m:Loop Loop myfun=m End Function Private Sub Command1_Click() Print myfun(9,8) End SubA.2B.1C.4D.3
考题
下列程序的运行结果是( )。Private Function myfun(m,n)Do While mnDo While mn:m=m-n:LoopDo While nm:n=n-m:LoopLoopmy fun=mEnd FunctionPrivate Sub Command1_Click()Print myfun(9,8)End SubA.2B.1C.4D.3
考题
下列程序的运行结果是( )。Private Function myfun(m,n)Do while mnDo While mn:m=m-n:LoopDo While nm:n=n-m:LoopLoopmyfun=mEnd FunctionPrivate Sub Command1_Click( )print myfun(9,8)End SubA.2B.1C.4D.3
考题
单击命令按钮时,下列程序的运行结果为 Private Sub Command1_Click() Print MyFund(20,18) End Sub Public Function MyFund(m As Integer,n As Integer)As Integer Do While m<>n Do While m>n:m=m-n:Loop Do While m<n:n=n-m:Loop Loop MyFund=m End FunctionA.0B.2C.4D.6
考题
窗体上有一个名称为Command1的命令按钮,并有如下程序: Private Sub Command1Click( ) Dim m As Integer,n As Integer m=InputBox("输入第一个数") nzInputBox("输入第二个数") Do While mn Do While mn m= m-n Loop Do While nm n=n-m Loop Loop Print m End Sub 该程序的功能是( )。A.求数值m和n的最大公约数B.求数值m和n的最小公倍数C.求数值m和n中的较大数D.求数值m和n中的较小数
考题
单击命令按钮时,下列程序的运行结果为Private Sub Command1_Click()Print Fun(23, 18)End SubPublic Function Fun(m As Integer, n As Integer) As IntegerDo While m nDo While m n: m=m - n: LoopDo While m n: n=n - m: LoopLoopFun=mEnd FunctionA.0B.1C.3D.5
考题
阅读下面的程序; Function Func(x As Integer,y As Integer)As Integer Dim n As Integer Do While n < = 4 x=x + y n = n + 1 Loop Func=x End Function Private Sub Command1_Click() Dim x As Integet, y As Integer Dim n As Integer,z As Integer x=1 y=1 For n = 1 To 6 z=Func(x,y) Next n Print z End Sub 程序运行后,单击命令按钮,输出的结果为.A.16B.21C.26D.31
考题
在窗体中添加一个名称为Commandl的命令按钮,然后编写如下事件代码:Private Sub Commandl Click( ) MsgBox f(24,18)End Sub Public Function f(m As Integer,n As Integer)As"integerDo While mn Do While mn m=m-n Loop Do While mn n=n-m Loop Loop f=m End Function 窗体打开运行后,单击命令按钮,则消息框的输出结果是( )。A.2B.4C.6D.8
考题
单击命令按钮时,下列程序的运行结果为 Private Sub Command1_Click( ) Print MyFund(20,18) End Sub Public Function MyFund(m As Integer,n As Integer)As Integer Do While m◇n Do While mn:m=m-n:Loop Do While m<n:n=n-m:Loop Loop MyFund=m End FunctionA.0B.2C.4D.6
考题
单击命令按钮时,下列程序代码的执行结果为 Private Sub Command1_Click( ) Print MyFunc(24,18) End Sub Public Function MyFunc(m As Integer,n As Integer)As Integer Do While m ◇ n Do While mn:m=m—n:Loop DO While m<n:n=n-m:Loop Loop My Func=m End FunctionA.2B.4C.6D.8
考题
单击命令按钮时,下列程序的运行结果为Private Sub Command1_Click()Print MyBM(23, 18)End SubPublic Function MyBM(m As Integer, n As Integer) As IntegerDo While m nDo While m n: m=m - n: LoopDo While m n: n=n - m: LoopLoopMyBM=mEnd Function( )。A.0B.1C.3D.5
热门标签
最新试卷