网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)
单选题
语句cout<<(1|2)<<","<<(1||2)<< endl;的输出结果是()
A

0,0

B

1,1

C

2,0

D

3,1


参考答案

参考解析
解析: 暂无解析
更多 “单选题语句cout(1|2)","(1||2) endl;的输出结果是()A 0,0B 1,1C 2,0D 3,1” 相关考题
考题 语句cout(a=2)(b=-2);的输出结果是( )。A.无输出B.结果不确定C.-1D.1

考题 对于语句“cout<<setfill(*)<<setw(10)<<1<<serfill(*)<<setw(2)<<2;”的输出结果是( )。A.*********1*2B.********12C.*******1*2D.12********

考题 ( 20 )已知数组 arr 的定义如下:int arr[5] = {1,2,3,4,5};下列语句中输出结果不是 2 的是A ) cout *arr+1 endl;B ) cout *(arr+1)endl;C ) cout arr[1] endl;D ) cout *arr endl;

考题 已知数组arr的定义如下: intarr[5]={1,2,3,4,5};下列语句中输出结果不是2的是( )。A.cout*arr+1endl;B.COUt*(art+1)endl;C.coutarr[1]endl;D.COUt*arrendl:

考题 以下程序的输出结果是_____。 include void fun( ) {static int a=0; a+=2;cout 以下程序的输出结果是_____。include<iostream.h>void fun( ){ static int a=0;a+=2;cout < < a < < " ";}void main( ){ int cc;for(cc=1;cc<4;cc++)fun( ) ;cout < < endl;}

考题 下列程序的输出结果是______。 includevoid main( ){ char a[]="abcdabcabfgacd"; in 下列程序的输出结果是______。include<iostream.h>void main( ){char a[]="abcdabcabfgacd";int i1=0,i2=0,i=0;while(a[i]){if(a[i]=="a")i1++;if(a[i]=="b")i2++;i++;}cout<<i1<<""<<i2<<endl;}

考题 已知数组arr的定义如下: int arr[5]={1,2,3,4,5}; 下列语句中,输出结果不是2的是A.cout<<*arr+1<<endl;B.tout<<*(arr+1)<<endl;C.cout<<arr[1]<<endl;D.eout<<%arr<<endl;

考题 有以下程序 #include"iostream.h" void main() { inti=l,j=1,k=2; if ((j++{}k++)i++) cout<< i << " ," << j << "," << k; cout<<endl; 执行后输出结果是A.1,1,2B.2,2,1C.2,2,2D.2,2,3

考题 有如下程序: #includediostream usingnamespacestd; classTestClass {private: intX,y; public: TestClass(inti,intj) {x=i; y=j;} voidprint() {cout"printl"endl;} voidprint()const {cout"print2"endl;}}; intmain() {constTestClassa(1,2); print(); return0;} 该程序运行后的输出结果是( )。A.printlB.print2C.printlprint2D.程序编译时出错

考题 下列程序的输出结果是【】。 include void main() { int i(1),j(2),k(3),a(10); if(!i 下列程序的输出结果是【 】。include<iostream.h>void main(){int i(1),j(2),k(3),a(10);if(!i)a--;else if(j)if(k)a=5;elsea=6;a++;cout<<a<<endl;if(i<j)if(i!=3)if(!k)a=1;else if(k)a=5;6+=2;cout<<a<<endl;

考题 以下三条输出语句分别输出什么?char str1[] = "abc";char str2[] = "abc";const char str3[] = "abc";const char str4[] = "abc";const char* str5 = "abc";const char* str6 = "abc";cout boolalpha ( str1==str2 ) endl; // 输出什么?cout boolalpha ( str3==str4 ) endl; // 输出什么?cout boolalpha ( str5==str6 ) endl; // 输出什么?

考题 有以下程序 #include"iostream.h" void main( ) { int i=1,j=1,k=2; if((j++||k++)i++) cout<<i<<","<<j<<","<<k; cout<<endl; } 执行后输出结果是A.1,1,2B.2,2,lC.2,2,2D.2,2,3

考题 有以下程序main( ){ int a=5,b=4,c=3,d=2;if(a>b>c)cout<<d<<endl;else if((c-1=d)==1)cout<<d+1<<endl;elsecout<<d+2<<endl;}执行后输出结果是A.2B.3C.4D.编译时有错,无结果

考题 如下程序的输出结果是main( ){int a=2,b=-1,c=2;if(a<B)if(b<0)c=0else c++;cout<<c<<endl;}A.0B.1C.2D.3

考题 下列语句中,输出与众不同的是A.cout<<"1."<<setfill('')<<"Hello!"<<endl;B.cout<<"1."<<''<<"Hello! \n";C.cout<<"1. Hello!"<<endl;D.cofit<<"1."<<setw(7)<<"Hello!";

考题 以下程序的执行结果是______. include c1ass A { public: virtual void funl () 以下程序的执行结果是______.include<iostream.h>c1ass A{public:virtual void funl () { cout<<"A fun1"<<endl;}virtual void fun2 () {cout<<"A fun2"<<endl;void fun3 () {cout<<" A fun 3 "<<endl:)void fun4 () {cout<<" A fun4 "<<endl:}

考题 下面程序的输出结果是______。include void main() { inta[6]={1,2,3,4,5,6}; for(in 下面程序的输出结果是______。include<iostream.h>void main(){inta[6]={1,2,3,4,5,6};for(int i=0;i<5;i++)cout<<a[i]<<““;cout<<endl;

考题 语句cout(33) endl;的输出结果是()A、24B、12C、9D、6

考题 语句cout(1|2)","(1||2) endl;的输出结果是()A、0,0B、1,1C、2,0D、3,1

考题 语句cout(12)","(12) endl;的输出结果是()A、0,0B、0,1C、1,0D、1,1

考题 以下语句中,输出结果与众不同的一个是()A、cout<<"1. "<<setfill(’ ’)<< "Hello! "<<endl;B、cout<<"1."<<’ ’ <<"Hello! /n";C、cout<<"1. Hello! "<<endl;D、cout<<"1. "<<setw(7)<< "Hello! ";

考题 语句cout(2^5) endl;的输出结果是()A、1B、3C、7D、10

考题 设有char *s="ABCDE";cout (s+1) endl;输出结果是()A、AB、BC、ABCDD、BCD

考题 单选题语句cout(2^5) endl;的输出结果是()A 1B 3C 7D 10

考题 单选题语句cout(12)","(12) endl;的输出结果是()A 0,0B 0,1C 1,0D 1,1

考题 单选题语句cout(33) endl;的输出结果是()A 24B 12C 9D 6

考题 单选题语句cout3) endl;的输出结果是()A 12B 9C 6D 3