题目详情
当前位置:首页 > 职业培训考试
题目详情:
发布时间:2023-10-20 00:33:28

[单项选择]下列程序的输出结果为( )。 # include < iostream.h> void main( ) { char * a[ ]={"hello","the","world"}; char * * pa=a; pa ++; cout << * pa <<endl; }
A. hello
B. the
C. world
D. hellotheworld

更多"下列程序的输出结果为( )。 # include < i"的相关试题:

[单项选择]下面的程序输出结果是( )。 #include<iostream> using namespace std; void add( ) { static int x; x++; cout<<x<<''; } int main( ) { for(int i=0;i<3;i++) add( ); return 0; }
A. 111
B. 123
C. 222
D. 333
[单项选择]下面程序的输出结果是 #include<iostream.h> #include<string.h> void main( ) { char p1[10],P2[10]; strcpy(p1,"abc"); strcpy(p2,"ABC"); char str[50]="xyz"; strcpy(str+2,strcat(P1,p2)); cout<<six; }
A. xyzabcABC
B. zabcABC
C. xyabcABC
D. yzabcABC
[单项选择]下面程序输出结果是 ______。 #include<iostream. h> void main( ){   int a,b,c; a=6;b=c=4; if(a!=B) if(a!=B) if(a) cout<<(a-->2); else a++; else a+=a; cout<<a; }
A. 15
B. 07
C. 12
D. 17
[单项选择]以下程序输出的结果是 #include<stdio.h> #include<string.h> main( ) {charw[][10]={"ABCD","EFGH","IJKL","MNOP"}1,k; for(k=1;k<3;k++) printf("%s/n",&w[k][k]);}
A. ABCD FGH KL
B. ABC EFG U M
C. EFG JK 0
D. FGH KL
[单项选择]以下程序的输出结果是 #include <stdio.h> #include <string,h> main( ) { char b1[8]="abcdefg",b2[8],*pb=b1+3; while (--pb>=b1) strcpy(b2,pB) ; printf("%d/n",strlen(b2)); }
A. 8
B. 3
C. 1
D. 7
[单项选择]以下程序的输出结果是 ( ) #include<stdio.h> #include<string.h> main( ) {char str[12]={'s','t','r','i','n','g'}; printf("%d/n",strlen(str)); }
A. 6
B. 7
C. 11
D. 12
[单项选择]以下程序的输出结果是()。 #include #include main() {charb1[8]="abcdefg",b2[8],*pb=b1+3; while(--pb>=b1)strcpy(b2,pb); printf("%d/n",strlen(b2)); }
A. 8
B. 3
C. 1
D. 7
[单项选择]以下程序输出结果是 ______。 #include<iostream.h> void fun(int x,int y,int z){z=x+y;} void main( ) { int a=10; fun (2,2,a); cout<<a; }
A. 0
B. 4
C. 10
D. 无定值
[单项选择]如下程序的输出结果是 #include<iostream> using namespaee std; int main( ){ eout.fill('*'); eout.width(6); cout.fill('#'): eout<(123<endl: return 0; }
A. ###123
B. 123###
C. ***123
D. 123***
[单项选择]如下程序的输出结果是 #include<iostream> using namespace std; class A{ public: A( ){cout<<"A";} }; class B{public:B( ){cout<<"B";}}; class C://public A{ B b; public: C( ){cout<<"C";} }; int main( ){C obj;return 0;}
A. CBA
B. BAC
C. ACB
D. ABC
[单项选择]以下程序的输出结果是 #include<iostream> using nameSpace std; int main( ) { cout.fill('*'); cout.width(5); cout<<hex<<100<<end1; return 0; }
A. **100
B. ***64
C. 100**
D. 64***
[单项选择]下列程序的输出结果是 #include"iostream" using namespace std; int Max(int a,int b) { if (a > b) return a; else return b; } void main( ) { int m,n; m=10,n=5; int max=Max(m,n); cout<<max<<endl; }
A. 10
B. 程序有误
C. 1
D. 0
[单项选择]下面程序的输出结果是 #include<stdio.h> #include<string.h> main( ) { char*p1="abc",*p2="ABC",str[50]="xyz"; strcpy(str+2,streat(p1,p2)); printf("%s/n",str);}
A. xyzabcABC
B. zabcABC
C. xyabcABC
D. yzabcABC
[单项选择]以下程序运行后的输出结果是 #include #include main( ) { char str[][20]={'One * World", "One * Dream!"}, *p=str[1]; printf("%d,", strlen(p)); printf("%s/n", p); }
A. 9,One * World
B. 9,One * Dream
C. 10,One * Dream!
D. 10,One * World
[单项选择]下面程序的输出结果是( )。 #include<iostream.h> #include"stdng.h" void main( ) { char a[]="welcome",b[]="well"; strcpy(a,b); cout<<a<<endl; }
A. wellome
B. wellcom
C. well
D. wellwe
[单项选择]以下程序的输出结果是( )。 #include <stdio.h> #include<string.h> mam( ) { char b1[8]="abcdefg",b2[8],*pb=b1+3; while(--pb>=b1) strcpy(b2,pB) ; printf("%d/n",strlen(b2)); }
A. 8
B. 3
C. 1
D. 7

我来回答:

购买搜题卡查看答案
[会员特权] 开通VIP, 查看 全部题目答案
[会员特权] 享免全部广告特权
推荐91天
¥36.8
¥80元
31天
¥20.8
¥40元
365天
¥88.8
¥188元
请选择支付方式
  • 微信支付
  • 支付宝支付
点击支付即表示同意并接受了《购买须知》
立即支付 系统将自动为您注册账号
请使用微信扫码支付

订单号:

请不要关闭本页面,支付完成后请点击【支付完成】按钮
恭喜您,购买搜题卡成功
重要提示:请拍照或截图保存账号密码!
我要搜题网官网:https://www.woyaosouti.com
我已记住账号密码