网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
14、1=formal 2=informal 答案填写数字1或2 “Love” can be used to end a(n) ________ letter.
参考答案和解析
非正式的
更多 “14、1=formal 2=informal 答案填写数字1或2 “Love” can be used to end a(n) ________ letter.” 相关考题
考题
下面是一段Pascal程序: for h:=1 tO n-1 dO begin x:=A[h+1]; k:=h; while (k>=1) and (A[k]>x) do begin A[k+1):=A[k]; k:=k-1 end; A[k+1]:=x end; 假设在程序开始执行时,数组A[1..n)是一组随机整数。下列答案中,哪一个最好的描述了最差情况下的程序执行时间(运行时间阶数)?( )A.0(nlog2n)B.O(n)C.0(log2n)D.O(n2)
考题
有如下事件过程:Private Sub Command1_Click()Dim m As Integer, n As Integerm=2: n=1Print "m="; m; "n="; nCall TOD(m, n)Print "m="; m; "n="; nEnd SubSub TOD(x, y)x=x ^ 2y=y ^ 3End Sub程序运行后,输出的结果为( )。A.m=2,n=1m=1,n=2B.m=2,n=1m=4,n=1C.m=1,n=2m=1,n=4D.m=1,n=2m=2,n=4
考题
下列程序段的执行结果为m=1n=1Select Case mCase 1Select Case nCase 0Print "**0**"Case 1Print "**1**"End SelectCase 2Print "**2**"End Select( )。A.**0**B.**1**C.**2**D.0
考题
有如下程序; Private SubForm_Click() Dim check As Boolean,n As Integer check=False n=0 Do Do While n<10 n=n+1 If n=5 Then check=True Exit Do End if Print n; Loop Loop Until check = True End Sub 程序运行后,输出的结果是 ______ 。A.1 2 3B.1 2 3 4C.1 2 3 4 5D.1 2 3 4 5 6
考题
下面是一段Pascal程序: for h:=1 to n-1 do begin x:=A[h+1]; k:=h; while(k>=1)and(A[k]>x)do begin A[k+1]:=A[k]; k:=k-1 end; A[k+1]:=x end; 假设在程序开始执行时,数组A[1…n)是一组随机整数。下列答案中,最好地描述了最差情况下的程序执行时间(运行时间阶数)的是A.O(n log2n)B.O(n)C.O(log2n)D.O(n2)
考题
(25)在窗体上有一个命令按钮Commandl,编写下列程序: Private Sub Command1_Click() Print ppl(3,7) End Sub Public Funcion ppl(x As Single,n As Integer)As Single If n=0 Then ppl=1 Else If n Mod 2=1 Then ppl=x*x+n Else ppl=x*x-n End If End If End Funcion 程序运行后,单击该命令按钮,屏幕上显示的是 A.2 B.1 C.0 D.16
考题
运行以下程序后,输出结果为_____________。 Private Sub Command1_Click() a=1:b=2:c=3 Call test(a,b+3,(c)) Print "main:";a;b;c End Sub Private Function test(p,m,n) p=p+1:m=m+1:n=n+1 Print "sub:";p;m;n End Function:A. sub:2 6 4 main:1 2 3B. sub:2 6 4 main:2 2 3C. sub:2 6 4 main:2 6 4D. sub:2 6 4 main:1 6 4
考题
有如下事件过程: Private Sub Command1_Click( ) Dim m AS Integer,n AS Integer m=2:n=1 Print "m=";m;"n=";n Call TOD(m,n) Print "m=";m;"n=";n End Sub Sub TOD(x,y) x=x^2 y=y^3 End Sub 程序运行后,输出的结果为A.m=2,n=1 m=1,n=2B.m=2,n=1 m=4,n=1C.m=1,n=2 m=1,n=4D.m=1,n=2 m=2,n=4
考题
Which of the following is NOT a type of business report?A: Short informal reportB: Short formal reportC: Extended formal reportD: Meeting report
考题
下面程序的执行结果是【】。include void main(){int n=0,x=0;do{n++;if(n%3==2do{n++;if(n%3==2n%5==3n%7==2)x=1;}while(x!=1);cout<<"n=" <<n<<end1;}
考题
有如下程序: Private Sub Commandl_Click( ) Dim i As Integer For i=1 To 2 DS Next i End Sub Sub DS( ) Dim x As Integer,m As String Static y,n X=X + 1 y=y + 1 m=m "*”:n=n"#" Print x,y,m,n End Sub 程序运行后,输出的结果是A.1 1 * #B.1 1 * #C.1 1 * # 1 1 * # 1 2 * #D.1 1 * # 1 1 * ## 1 2 * ##
考题
在窗体中添加一个命令按钮,编写如下程序: Private Sub Subl(p,m,n) p=p+1:m=m+1:n=n+1 Print"subl:";p;m;n End Sub Private Sub Command1_Click() al=1:b=2:c1=3 Call Subl(a,b1+3,c1) Print"Main:";a1;b1;c1 End Sub 程序运行后,输出结果为A.Sub:2 6 4 Main:2 6 4B.Sub:2 6 4 Main:2 6 4C.Sub:2 6 4 Main:1 2 3D.Sub:2 6 4 Main:2 2 3
考题
当发生窗体的单击事件时,输出的第二行为( )。 Private Sub Form_click() Dim N1 As Integer,N2 As Integer,N3 As Integer N1=1:N2=1 Print N1;N2 Do N3=N1+N2 Print N3; N1=N2:N2=N3 Loop Until N3>=5 End SubA.1 1 1B.2 3 5C.2 5 7D.2 3 4
考题
以下程序段中Do...Loop 循环执行的次数为【 】。程序执行完毕后,n的值为【 】。Private Sub Command1_Click()n =5DoIf n Mod 2= 0 Thenn =n \2Elsen =n* 3 + 1End IfLoop Until n=1End Sub
考题
下列程序段的执行结果为 m=1 n=1 Select Case m Case 1 Select Case n Case 0 print"A" Case 1 Print"B" End Select Case 2 Print"C" End SelectA.AB.BC.CD.0
考题
有如下事件过程: Private Sub Commaild1_Click( ) Dim i As Integer For i =1 To 2 DC Next i End Sub Sub DC( ) Dim x As Integer,m As String Static y,n x=x + 1 y=y + 1 m=m"*":n=n "#" Print x,y,m,n End Sub 程序运行后,输出的结果是A.1 1 * # 1 1 * #B.1 1 * # 1 2 * #C.1 1 * # 1 1 * ##D.1 1 * # 1 2 * ##
考题
在窗体上有一个命令按钮Command1,编写如下程序: Private Sub Command1_Click() Print pp1(3, 7) End Sub Public Function pp1(x As Single, n As Integer) As Single If n = 0 Then pp1= 1 Else If n Mod 2 = 1 Then pp1 =x*x+n Else pp1 =x*x-n End If End If End Function 程序运行后,单击该命令按钮,屏幕上显示的是( )。A.2B.1C.0D.16
考题
以下程序段中Do...Loop循环执行的次数为( )。 n=5 Do lf n Mod 2=0 Then n=n\2 Else n=n*3+1 End If Loop untiln=1A.4B.3C.5D.2
考题
下列程序段的执行结果为 m=1 n=1 Select Case m Case 1 Select Case n Case 0 Print" * * 0 * *" Case 1 Print" * *1* *" End Select Case 2 Print" * * 2 * *" End SelectA.**0**B.**1**C.**2**D.0
考题
在窗体中添加一个命令按钮,编写如下程序: Private Sub Test(p,m,n) p=p+1:m=m+1:n=n+1 Print "Sub: ";p;m;n End Sub Private Sub Command1.Click() a1=1:b=2:c1=3 Call Test((a,b1+3,(c1)) Print "Main:";a1;b1;c1 End Sub 程序运行后,输出结果为A.Sub: 2 6 4 Main: 2 6 4B.Sub: 2 6 4 Main: 2 6 4C.Sub: 2 6 4 Main: 1 2 3D.Sub: 2 6 4 Main: 2 2 3
考题
以下程序段中Do...Loop循环执行的次数为______。 n=5 Do if n mod 2=0 then n=n\2 else n=n*3+1 end if Loop until n=1A.4B.3C.5D.2
考题
下列程序段的执行结果为 m=1 n=1 Select Case m Case 1 Select Case n Case 0 Print" * * 0 * *" Case 1 Print" * *.* *" End Select Case 2 Print"* *,2 * *," End SelectA.* * 0 * *B.* * 1 * *C.* * 2 * *D.0
考题
单击一次命令按钮之后,在对话框中输入12,2,34,23,窗体中的输出结果为______。 Private Sub Command1_ Click () Dim a(4) As Integer For i = 1 To 4 a (i) = Val (InputBox (“请输入元素”)) Next i plus a(1), a(2), a(3) End Sub Sub plus(first As Integer, second As Integer, third As Integer, Optional forth) n = first + second + third If Not IsMissing (forth) Then n = n + forth End If Print n End SubA.14B.71C.48D.37
考题
for循环语句“for(i=0;iA(n+1)/2Bn/2+1Cn/2-1Dn-1 正确答案 A 答案解析 略 rewardHtml()A(n+1)/2Bn/2+1Cn/2-1Dn-1
考题
for(int i=0;iAn2B(n+1)/2Cn(n-1)/2Dn(n+1)/2 正确答案 D 答案解析 略 rewardHtml()An2B(n+1)/2Cn(n-1)/2Dn(n+1)/2
考题
单选题public class TwoThreads { private static Object resource = new Object(); private static void delay(long n) { try { Thread.sleep(n); } catch (Exception e) { System.out.print(”Error “); } } public static void main(String[] args) { System.out.print(”StartMain “); new Thread1().start(); delay(1000); Thread t2 = new Thread2(); t2.start(); delay(1000); t2.interrupt delay(1000); System.out.print(”EndMain “); } static class Thread 1 extends Thread { public void run() { synchronized (resource) { System.out.print(”Startl “); delay(6000); System.out.print(”End1 “); } } } static class Thread2 extends Thread { public void run() { synchronized (resource) { System.out.print(”Start2 “); delay(2000); System.out.print(”End2 “); } } } } Assume that sleep(n) executes in exactly m milliseconds, and all other code executes in an insignificant amount of time. What is the output if the main() method is run?()A
Compilation fails.B
Deadlock occurs.C
StartMain Start1 Error EndMain End1D
StartMain Start1 EndMain End1 Start2 End2E
StartMain Start1 Error Start2 EndMain End2 End1F
StartMain Start1 EndMain End1 Start2 Error End2
热门标签
最新试卷