网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
以下程序的输出结果是()。 ls=[[1,2,3],’Python’,[[4,5,’ABC’],6],[7,8]] print(ls[2][1])
A.'ABC'
B.[4,5, 'ABC']
C.6
D.[7,8]
参考答案和解析
6
更多 “以下程序的输出结果是()。 ls=[[1,2,3],’Python’,[[4,5,’ABC’],6],[7,8]] print(ls[2][1])A.'ABC'B.[4,5, 'ABC']C.6D.[7,8]” 相关考题
考题
下面程序运行后的输出结果是( )。struct abc{int a,b,c;}main(){struct abc s[2]={{1,2,3},{4,5,6}};int t;t=s[0].a+s[1].b;printf("%d\n",t);}A.5 B.6 C.7 D.8
考题
下列程序的输出结果是()。inclUdemain(){inta[2][3]={{1,2,3},{4,5,6}},(*p)[3],i;p=a;
下列程序的输出结果是( )。 #inclUde<stdio.h> main() { inta[2][3]={{1,2,3},{4,5,6}},(*p)[3],i; p=a; for(i=0;i<3;i++) { if(i<2) p[1][i]=p[1][i]-1; else p[1][i]=1; } printf("%d\n",a[0][1]+a[1][1]+a[1][2]; }A.15B.10C.7D.8
考题
语句:print sgn(-6^2)+Abs(-6^2)+int(-6^2)的输出结果是( )A.-36B.1C.-1D.-7252967.以下语句a=sqr(3)print format(a,####.###)的输出结果是( )A.1.732B. 0001.732C.###1.732D. 1.7320
考题
下列程序的输出结果是( ) struct abc { int a,b,c;}; main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t); }A.3B.4C.5D.6
考题
下列程序的输出结果是()。includestruct abc{int a, b, c, s;};main(){struct abc s[2]
下列程序的输出结果是( )。 #include <stdio.h> struct abc { int a, b, c, s;}; main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t); }A.5B.6C.7D.8
考题
以下程序的输出结果是 ______。define NULL 0includevoid main(){ int a[]={1,2,3,
以下程序的输出结果是 ______。 #define NULL 0 #include<iostream.h> void main(){ int a[]={1,2,3,4,5,6,7,8,9,10}; int *p=a+5,*q=NULL; *q=*(p+5); cout<<*p<<’ ’<*q; }A.运行后报错B.6 6C.6 11D.5 5
考题
以下程序的输出结果是()includemain(){chars1[]="123",s2[]="abc",ss[20]="010";strc
以下程序的输出结果是 ( ) #include<string.h> main() {char s1[]="123",s2[]="abc",ss[20]="010"; strcat(ss+1,strcpy(s2,s1)); printf("%s\n",ss); }A.10123B.0abcC.1123D.01abc
考题
有如下程序段struct abc{ int a, b, c, s;};main(){ struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t);}程序运行后输出的结果是A.5 B.6 C.7 D.8
考题
有以下程序: 程序运行后的输出结果是( )。 A.3,3,3B.2,2,3C.1,2,3
有以下程序:程序运行后的输出结果是( )。A.3,3,3B.2,2,3C.1,2,3D.1,l,3
考题
若有以下程序段: int r=8; print("%d\n",r1): 输出结果是( )。 A.16B.8S
若有以下程序段: int r=8; print("%d\n",r1): 输出结果是( )。A.16B.8C.4D.2
考题
语句Print Sgn(-6^2)+Abs(-6^2)+Int(-6^2)的输出结果是( )。A.-36B.1C.-1S
语句Print Sgn(-6^2)+Abs(-6^2)+Int(-6^2)的输出结果是( )。A.-36B.1C.-1D.-72
考题
有以下程序: #includeiostream usingnamespacestd; classR {public: R(intr1,intr2) {R1=r1; R2=r2;} voidprint(); voidprint()const; private: intR1,R2;}; voidR::print() {coutR1","R2endl;} voidR::print()const {coutR1","R2endl;} intmain() {Ra(5,4); constRb(20,52); print(); return0;} 执行后的输出结果是( )。A.5,4B.20,52C.0,0D.4,5
考题
有以下程序:includeusingnamespacestd;int main (){ int a[]={1,2,3, 4,5, 6, 7,8,9,
有以下程序: #include<iostream> using namespace std; int main () { int a[]={1,2,3, 4,5, 6, 7,8,9, 10, 11, 12}; int *p=a+5, *q=0; *q=* (p+5); cout<<*p<<" "<<*q<<end1; return 0; }A.运行后报错B.66C.6 12D.5 5
考题
判断题在Python3.x中语句print(*[1,2,3])不能正确执行。A
对B
错
热门标签
最新试卷