A.0
B.1
C.2
D.3
第1题
A.0
B.1
C.2
D.3
第2题
执行下列程序段,结果是 #include<iostream.h> void main() { int x=40; char y='C'; int n; n=(x&0xff)&&(y>'B'); cout<<n;}
A.0
B.1
C.2
D.3
第3题
执行下列程序段,结果是 #include(iostream.h> void main() { int x=40; char y=‘C’;int n; n=(x&0xff)&&(y>‘B’); cout<<n;}
A.0
B.1
C.2
D.3
第4题
下列程序段的输出结果是 #include<iostream.h> void fun(int * X,int * y) { cout < < * X < < * y; * X=3; * y=4; } void main() { int x=1,y=2; fun(&y,&x); cout < < X < < y < < end1; }
A.2143
B.1212
C.1234
D.2112
第5题
下列程序段的输出结果是 #include<iostream.h> void fun(int * x,int * y) { cout << * X << * y; *X=3; *y=4; } void main() { int x=1,y=2; fun(&y,&x); cout << X << y<<endl; {
A.2143
B.1212
C.1234
D.2112
第6题
下列程序段的输出结果是 #include<iostream.h> void fun(int*x,int*y) {cout<<*x<<*y; *X=3; *y=4; } void main() {int x=1,y=2; fun(&y,&x); cout<<X<<y<<endl; }
A.2143
B.1212
C.1234
D.2112
第7题
下列程序的执行结果是()。 #inClude<iostream.h) #include(stdlib.h) class TestClass { public: int x,y; TestClass(){x=y=0;} TestClass(int a,int b){x=a;y=b;} void disp() { cout<<"x="<<x<<",y="<<y<<endl; } }; void main() {
A.x=2,y=2
B.x=2,y=3
C.x=3,y=2
D.x=3,y=3
第8题
下列程序段的输出结果是 #include<iostream.h> void fun(int*x,int*y) { cout<<*x<<*y; *x=3; *y=4; } void main() {int x=1,y=2; fun(&y,&x); cout<<x<<y<<endl; }
A.2143
B.1212
C.1234
D.2112
第9题
下列程序的执行结果是()。 #include<iostream.h> #include<stdlib.h> Class TestClass { public: int x,y; TestClass(){x=y=0;} TestClass(int a,int b){x=a;y=b;} void disp() { cout<<"x="<<x<<",y="<<y<<end1; } }; void main() { TestClass s1(2,3); s1.disp(); }
A.x=2,y=2
B.x=3,y=3
C.x=2,y=3
D.x=3,y=2
第10题
以下程序的执行结果是【 】。
include<iostream.h>
include<stdlib.h>
class Sample
{
public:
int x,y;
Sample(){x=y=0;}
Sample(int a,int b) {x=a;y=b; }
void disp()
{
cout<<"x="<<x<<",y="<<y<<end1;
}
};
void main() {
Sample s1(2,3);
s1.disp();
}
为了保护您的账号安全,请在“上学吧”公众号进行验证,点击“官网服务”-“账号验证”后输入验证码“”完成验证,验证成功后方可继续查看答案!