网友您好, 请在下方输入框内输入要搜索的题目:
题目内容
(请给出正确答案)
下面程序的输出结果为( )。
A.x=99
B.x=9
C.x=0
D.异常
参考答案
更多 “ 下面程序的输出结果为( )。A.x=99B.x=9C.x=0D.异常 ” 相关考题
考题
下面程序的输出结果为______ include void main() {cout
下面程序的输出结果为______include<iostream.h>void main(){cout<<"Hello\b";}
考题
下面程序的输出结果是 ( )main( ){ int x,y,z;x=0,y=z=-1;x+=-z- - -y;pritnf("x=%d\n",x);}A.x=4B.x=0C.x=2D.x=3
考题
下面程序的输出结果为【】。 include main() { char a[]="morning",t; int i,j=0; for(
下面程序的输出结果为【 】。include<iostream.h>main(){char a[]="morning",t;int i,j=0;for(i=1;i<7;i++)if(a[j]<a[i])j=i;t=a[j];a[j]=a[7];a[7]=a[j];cout<<a;}
考题
下面程序的输出结果为 【】 。 include void main( ) {int num=0,i=8;do{ i--; num ++
下面程序的输出结果为 【 】 。include<iostream.h>void main( ){int num=0,i=8;do{i--;num ++;}while(--i);cout<<num<<end1;}
考题
下面程序的输出结果为()。ineludevoid main(){int x;int y=x;//变量引用y=99;c
下面程序的输出结果为( )。 #inelude<iostream.h> void main() { int x; int y=x;//变量引用 y=99; cout<<"x="<<x<<end1; }A.x=99B.x=9C.x=0D.异常
考题
下面程序段的输出结果为( )。 packagetest; publicclassClassA { intx=20; staticinty=6; publicstaticvoidmain(Stringargs[]) { ClassBb=newClassB(); b.go(10); System.out.println("x="+b.x); } } classClassB { intX; voidgo(inty) { ClassAa=newClassA(); X=a.y; } }A.x=10B.x=20C.x=6D.编译不通过
考题
下面程序的输出结果为_____。 include void main( ) { in num=0,i=8; do{ i--; num+
下面程序的输出结果为_____。include<iostream.h>void main( ){in num=0,i=8;do{i--;num++;}while(--i) ;cout < < num < < endl;}
考题
下面程序的输出结果为【】。inclUdevoid main(){ int a;int b=a;//变量引用b=10;c
下面程序的输出结果为【 】。inclUde<iostream.h>void main(){int a;int b=a;//变量引用b=10;cout<<"a="<<a<<endl;}
考题
下列程序的输出结果为()。includevoid main(){int x;int y=x;//变量引用y=99;
下列程序的输出结果为( )。 #include<iostream.h> void main() { int x; int y=x;//变量引用 y=99; cout<<"x="<<x<<end1; }A.x=99B.x=9C.x=0D.异常
考题
下面程序的输出结果为 ______。includemain(){char pl [7]="abc",p[]2="ABC"str[50]="
下面程序的输出结果为 ______。 #include<string.h> main() { char pl [7]="abc",p[]2="ABC"str[50]="xyz"; strcpy(str,strcat(p1,p2)); printf("%s"str); }A.xyzabcABCB.abcABCC.xyzabcD.xyzABC
考题
下面这段程序将会产生什么结果:#includestdio.hint main(){int i=0;for(;i2;){i++;}printf(%d\n,i);return 0;}A.程序编译出错B.输出结果为2C.输出结果为1D.程序死循环
考题
下面程序的输出结果是 ( ) main( ) {int x,y,z; x=0;y=z=-1; x+=-z - - -y printf("x=%d\n",x); }A.x=4B.x=0C.x=2D.x=3
考题
在下面程序运行后,输出结果为 ______。includevoid count(int x[],int n,int y
在下面程序运行后,输出结果为 ______。 #include<iostream.h> void count(int x[],int n,int y){ int k; y=0; for(k=0:k<n;k++) if(x[k]<0) y++; } void main(){ int b[]={2,1,-8,-3,7,2,4,6,0,-13}; int x; count(b,10,x); cout<<“x”<<x<<end1; }A.x=3B.x=5C.出错D.x=0
考题
下面的程序 main( ) { int x=3; do{printf("%d\n",x-=2);} while(!(- -x)); }A.输出的是1B.输出的是1和-2C.输出的是3和0D.是死循环
考题
在下面的程序的横线处填上适当的语句,使该程序的输出结果为12。include using namespac
在下面的程序的横线处填上适当的语句,使该程序的输出结果为12。include<iostream>using namespace std;class TestClass{public:int a,b;TestClass(int i,int j){a=i;b=j;}};class TestCla
考题
单选题下面程序的输出结果为( )。A
x=99B
x=9C
x=0D
异常
热门标签
最新试卷