10、阅读以下程序,填写运行结果_________________. dic={'a':1,'b':9,'c':3,'d':5} lst=sorted(dic.items(),key=lambda x:x[1],reverse=True) print(lst[1][1])

10、阅读以下程序,填写运行结果_________________. dic={'a':1,'b':9,'c':3,'d':5} lst=sorted(dic.items(),key=lambda x:x[1],reverse=True) print(lst[1][1])


参考答案和解析
3

相关考题:

下列程序段,运行后窗体上输出结果是 Private Sub Commnad1_Click() a=5∶b=4∶c=3∶d=2 x=3>2*b Or a=c And b<>c Or c>d Print X End SubA. 1 B. True C. False D. 2

语句sorted([1,2,3],reverse=True)==reversed([1,2,3])执行结果为_________。

( 30 )下面程序运行时,若输入 395 ,则输出结果是Private Sub Comand1_Click ()Dim x%x=InputBox (" 请输入一个 3 位整数 ")Print x Mod 10,x\100, ( x Mod 100 ) \10End SubA ) 3 9 5B ) 5 3 9C ) 5 9 3D ) 3 5 9

(23)下列程序运行时输出的结果是 Option Base 1 Const a=10 Priate Sub Form_Click() Dim x(a) As Integer k=-1 For i=1 To a x(i)=i*k k=(-1)*k Next i For i=1 To 10 Print x(i) Next i End Sub A.1 3 5 7 9 10 B.-1 -3 -5 -7 -9 C.-1 2-3 4-5 6-7 8-9 10 D.1-2 3-4 5-6 7-8 9-10

下列程序的运行结果为【 】。A="1"B="2"A=Val (@A@+Val (@B@B=Val ("12")If A<>B Then Prink A-B Else Print B-A(11)阅读下列程序:Option Base 1Private Sub Form. Click()Dim x(3,3)For j=1 to 3For k=1 to 3If j=k then x(j,k)=1If j<> k then x(j,k)=3Next kNext jCall fun(x())End SubPrivate Sub fun(a())For j=l to 3For k=1 to 3Print a (j.k);Next kNext jEnd Sub运行程序时,输出的结果是【 】

假定有以下程序: Private Sub Form. Click( ) a=1:b=a Do Until a=5 x=a*b Print b;X a=a+b b=b+a Loop End Sub 程序运行后,单击窗体,输出结果是( )。A.1 1 2 3B.1 1 2 4C.1 1 3 8D.1 1 3 6

单击按钮时,以下程序运行后的输出结果是 Private Sub proc1(x As Integer,y As Integer,z As Integer) x=3*z y=2*z z=x+y End Sub Private Sub Command1_Click() Dim x As Integer,y As Integer,Z As Integer x=1:y=2:z=3 Call proc1(x,x,z) Print x;x;z Call proc1(x,y,y) Print x;y;y End SubA.6 6 12 `B.9 5 10 6101051010C.9 6 12D.9 10 10 910155410

阅读下面的程序: Private Sub Command1_Click() For i=1 To 3 For j=1 To i For k=j To 3 x=x+1 Next k Next j Next i Print x End Sub 程序运行后,单击命令按钮,窗体上输出的结果是A.3B.9C.14D.21

下列程序运行时输出的结果是 Option Base 1 Private Sub Form_Click() Dim x(10) As Integer,y(5) As Integer For i=1 to 10 x(i)=10-i+1 Next For i=1 to 5 y(i)=x(2*i-1)+x(2*i) Next For i=1 to 5 Print y(i) Next End SubA.3 7 11 45 19B.19 15 11 7 3C.1 3 5 7 9D.不确定的值

阅读下列程序。Option Base 1Private Sub Form. _Click()Dim x(3,3)For j=1 to 3For k=l to 3If j=k then x(j,k)=1If j<>k then x(j,k)=kNext kNext iCall fun(x())End SubPrivate Sub fun(x())For j=1 to 3For k=1 to 3Print x(j,k);Next kNext jEnd Sub运行程序时,输出结果为【 】。

下列程序段的执行结果为______。 x = 0: y = 1 z = 1: n = 0 Do x = x + y + z n = n + 1 Loop While x < 10 Print x; nA.10 5B.x nC.9 5D.10 6

有如下程序: Private Sub Command1_Click() as="A WORKER IS HERE" x = Len(a$) For i=1 To x - 1 b$ =Mid$(a$, i,3) If b$ ="WOR" Then S=S+ 1 Next Print S End Sub 单击命令按钮,程序运行结果为A.1B.2C.3D.5

以下程序运行后的输出结果是______。 Private Sub Form_ Click() y=1 :x=2 Print Iif(x>=y,x,y) End SubA.0B.1C.2D.3

执行下面这段程序后,单击命令按钮,窗体中输出结果是 ______。 Private Sub Command1_Click() a=1 : b=4 : c = 9 : d = 5 If a < b Then If c<d Then x=True Else If a<c Then x=False Else x=True End If End If End If Print Val(x) End SubA.TrueB.FalseC.0D.1

下面程序运行时,若输入395,则输出结果是( )。 Private Sub Command1_Click( ) Dim X% x=InpetBox("请输入一个3位整数") Print x Mod 10,x/100,(x Mod 100)/10 End SubA.3 9 jB.5 3 9C.5 9 3D.3 5 9

运行以下程序后,显示的结果为 ______。 Dim x(5) x(0) =1 For i=1 To 5 x(i)=x(i-1)*i Print x(i) Next i EndA.1 2 3 4 5B.1 2 6 24 120C.1 2 6 12 20D.1 1 2 3 4

单击按钮时,以下列程序运行后的输出结果是 Private Sub proc1(x As Integer,y As Integer,z As Integer) x=3*z y=2*z z=X+y End Sub Private Sub Command1_Click( ) Dim x As Integer,y As Integer,z As Integer x=1:y=2:z=3 Call proc1(x,x,2) Print x;x;z Call proc1(x,y,y) Print x;y;y End SubA.6 6 12 6 6 10B.9 5 10 5 10 10C.9 6 12 9 10 15D.9 5 10 5 4 10

以下程序输出什么?"""x=1"""whilex:print(x) A.运行结果显示NameError:name'x'isnotdefinedB.运行结果无限循环输出1C.它等价于下面的程序#x=1whilex:print(x)D.它等价于下面的程序whilex:print(x)

执行以下两条语句后,lst的结果是1. lst = [3, 2, 1]2. lst.append(lst)() A.[3, 2, 1, [3, 2, 1]]B.[3, 2, 1, […]],其中“…”表示无穷递归C.抛出异常D.[3, 2, 1, lst]

单击按钮时,以下程序运行后的输出结果是 Private Sub Commandl_Click( ) Dim X As Integer,y As Integer,z As Integer x=1:y=2: Z=3 Call God(x,x,z) Print x;x;z Call God(x,y,y) Print X;y;y End Sub Private Sub God(x As Integer,y As Integer,z As Integer) x=3 * Z + 1 y=2 * Z z=x + y End SubA.6 6 12 7 11 11B.8 5 10 5 11 11C.9 6 12 9 10 15D.8 10 10 5 9 10

int x=0  step1   for(; x  11 ; x++) {   if(x = = 6) {   x= 8   break step1;   }   if( x = = 3 ) {   x+ +   continue   }   System.out.print(x +“ ”);   }   结果为:()  A、0 1 2B、0 1 2 5C、0 1 2 4 5D、0 1 2 5 8 9 10E、0 1 2 5 8 9 10 11

已知x=[1,2,3,4,5],那么执行语句x[1::2]=sorted(x[1::2],reverse=True)之后,x的值为()。

下列程序段:Dim x If x Then Print x Else Print x+1运行后,显示的结果是()。A、1B、0C、-1D、出错

填空题语句sorted([1,2,3],reverse=True)==reversed([1,2,3])执行结果为()。

单选题int x=0  step1   for(; x  11 ; x++) {   if(x = = 6) {   x= 8   break step1;   }   if( x = = 3 ) {   x+ +   continue   }   System.out.print(x +“ ”);   }   结果为:()A0 1 2B0 1 2 5C0 1 2 4 5D0 1 2 5 8 9 10E0 1 2 5 8 9 10 11

单选题下列程序段:Dim x If x Then Print x Else Print x+1运行后,显示的结果是()。A1B0C-1D出错

单选题阅读下列程序 INTEGER M(3,3)   DATA  M/1,2,3,4,5,6,7,8,9/    WRITE(*,10)(M(3,J),J=1,3)     10 FORMAT(1X,3I2)     END  程序运行结果是()A2  5  8B3  6  9C4  5  6D7  8  9

填空题已知x=[1,2,3,4,5],那么执行语句x[1::2]=sorted(x[1::2],reverse=True)之后,x的值为()。