完成以下PL/SQL块,功能是:显示2 到50的25个偶数。 BEGIN FOR________ IN _________ LOOP DBMS_OUTPUT.PUT_LINE(even_number*2); END LOOP END;

完成以下PL/SQL块,功能是:显示2 到50的25个偶数。 BEGIN FOR________ IN _________ LOOP DBMS_OUTPUT.PUT_LINE(even_number*2); END LOOP END;


相关考题:

有如下程序; 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

单击命令按钮时,下列程序的运行结果为 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

(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

下列程序的运行结果是( )。 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

以下能够正确计算n!的程序是A.Private Sub Command1_Chck( ) n=5:x=1 Do x=x*i i=i+1 Loop While i<n Print x End SubB.Private Sub Command1_Click( ) n=5:x=1:i=l Do x=x*i i=i+1 Loop While i<n Print x End SubC.Private Sub Command1_Click( ) n=5:x=1:i=l Do x=x*i i=i+1 Loop While i<=n Print x End SubD.Private Sub Command1_Click( ) n=5:x=1:i=l Dox=x*i i=i+1 Loop While i>n Print x End Sub

对于如下程序,单击Co皿andl事件发生后,窗体上显示的内容为 ______。 Private Sub Command1_Click() Dim i As Integer,a a As Integer Do While i<20 Do While True If i Mod 10 = 0 Then Exit Do Else i=i-1 End If Loop i=i+11 a=a+1 Loop Print a End SubA.21B.32C.33D.11

以下能够正确计算n!的程序是A.Private Sub Command1 Click() n=5:x=1 Do x=x * I I=I + 1 Loop While I < n Print x End SubB.Private Sub Command1_Click() n=5:X=1:I=1 Do X=X*I I=I + 1 Loop While I <n Print x End SubC.Private Sub Command1_Click() n=5:X=1:I=1 Do X=X * I I=I + 1 Loop While I<=n Print X End SubD.Private Sub Command1_Click() n=5:X=1:I=1 Do x=x * I I=I + 1 Loop While I>n Print X End Sub

单击命令按钮时,下列程序代码的运行结果为 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

以下程序段中Do...Loop 循环执行的次数为【 】。程序执行完毕后,n的值为【 】。Private Sub Command1_Click()n =5DoIf n Mod 2= 0 Thenn =n \2Elsen =n* 3 + 1End IfLoop Until n=1End Sub

以下程序段中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

单击命令按钮时,下列程序的运行结果为 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

有以下程序: include using namespace std; int main() {int i=1,sum=0;Loop:if(i 有以下程序:include<iostream>using namespace std;int main(){int i=1,sum=0;Loop:if(i<=20){sum+=i;i++;goto Loop;}cout<<sum<<end1;return 0;}该程序运行后的输出结果是【 】。

单击命令按钮时,下列程序代码的执行结果为______ 。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

在窗体中添加一个名称为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

对于以下程序段,设a和q都是整型变量, ┇ a=q; Loop:if(a==0)goto End; Else if(a>0){printf("");a--;goto Loop;} Else goto End; End; ┇ 不能与上面程序等价的是( )A.a=q; do { f(a<0)break; a--;printf("*"); }while(a) ;B.a=q; for(;a>0;a--)printf("");C.a=q; while(a) {printf("");a--;}D.for(a=q;a>0;--a,printf("*"));

完成以下PL/SQL块,功能是:使用游标,显示所有单价低于250元的玩具的单价。DECLAREmy_toy_price toys.toyprice%TYPE; CURSOR toy_cur ISSELECT toyprice FROM toys WHERE toyprice______________ LOOP________________________________________ EXIT WHEN toy_cur%NOTFOUND;DBMS_OUTPUT.PUT_LINE (toy_cur%ROWCOUNT || '. 玩具单价:' || my_toy_price); END LOOP;CLOSE toy_cur; END;

在下面给出的PL/SQL代码块中,()行代码会导致失败。 1DECLARE 2vNumNUMBER:-100; 3BEGIN 4vNum-vNum/10; 5END;A、1B、2C、3D、4E、5F、全部语句都能够成功执行

在Oracle中,PL/SQL块中定义了一个带参数的游标:CURSOR emp_cursor(dnum NUMBER)IS SELECT sal,comm FROM emp WHERE deptno = dnum;那么正确打开此游标的语句是()A、OPEN emp_cursorB、OPEN emp_cursor FOR 20C、OPEN emp_cursor USING 20D、FOR emp_rec IN emp_cursor(20) LOOP … END LOOP

下面()不是oracle程序设计中的循环语句。A、for…end forB、loop…end loopC、while…end loopD、For…end loop

简述T-SQL语言中Begin…End语句的作用。

要退出Do Loop循环,可使用的语句是()语句。A、ExitB、Exit ForC、End DoD、Exit Do

PL/SQL的循环控制语句LOOP包括以下()类型。A、LOOPB、WHILE…LOOPC、IF…LOOPD、FOR…LOOP

Examine the following PL/SQL block:   SET SERVEROUTPUT ON SET LONG 10000 ECLARE report clob;  BEGIN report := DBMS_SPM.EVOLVE_SQL_PLAN_BASELINE(); DBMS_OUTPUT.PUT_LINE(report); END;   Which statement describes the effect of the execution of the above PL/SQL block?()  A、 The plan baselines are verified with the SQL profiles.B、 All fixed plan baselines are converted into nonfixed plan baselines.C、 All the nonaccepted SQL profiles are accepted into the plan baseline.D、 The nonaccepted plans in the SQL Management Base are verified with the existing plan baselines.

单选题A “bowline” is used to().Ajoin lines of equal sizeBform a temporary eye (loop) at the end of a lineCbe a stopperDkeep a line from fraying

多选题PL/SQL的循环控制语句LOOP包括以下()类型。ALOOPBWHILE…LOOPCIF…LOOPDFOR…LOOP

单选题Examine the following PL/SQL block:   SET SERVEROUTPUT ON SET LONG 10000 ECLARE report clob;  BEGIN report := DBMS_SPM.EVOLVE_SQL_PLAN_BASELINE(); DBMS_OUTPUT.PUT_LINE(report); END;   Which statement describes the effect of the execution of the above PL/SQL block?()A The plan baselines are verified with the SQL profiles.B All fixed plan baselines are converted into nonfixed plan baselines.C All the nonaccepted SQL profiles are accepted into the plan baseline.D The nonaccepted plans in the SQL Management Base are verified with the existing plan baselines.