-
下面程序的运行结果是______。#include#includevoidmain(){charp1[50]=”abc”,*p2,str[50]=abc
-
下面程序段的运行结果是( )注意输出结果的格式#include void main(){char *p=”abcdefgh”;p+=3;printf(%s\n,p);}
-
06410141:下面程序的运行结果是()。#include #include int main( ){char x[80]=\AB\, y[80]=\LMNP\;int n=0;strcat(x, y);while (x[n++]!='
-
下面程序的运行结果是______。 #include < stdio.h > #include < string.h > main() { char a[7]=\abcdef\,b[4]=\ABC
-
下面程序的运行结果为#include<iostream.h>void main( )char a='3';switch(
A.
 
-
下面程序的运行结果是()。 include<iostream.h
A.12 12
B.12 21
C.21 12
D.21 21
-
下面程序的运行结果是()。include<iostream.h> void main{int num=1:int&ref=num; ref
下面程序的运行结果是()。
include<iostream.h> void main
{
int num=1:
int&ref=num; ref=ref+2:
cout<<num: num=num+3: cout<<ref<<endl:
}
A.13
B.16
C.36
D.33
-
下面程序的运行结果是()。 include<iostream.h> void fun(int *a,int *B. { int x=*a
下面程序的运行结果是()。 include<iostream.h> void fun(int *a,int *B. { int x=*a: *a=*b;*b=X; cout<<*a<<*b<<””: void main { int X=1,Y=2; fun(&x,&y); cout<<x<<Y<<endl; }
A.12 12
B.12 21
C.21 12
D.21 21
-
有下列程序: include<stdi0.h> voidmain() {char*a[]={"abcd","ef","gh","ijk");inti; for(i=0;i<4;i++)printf("%C",*a[i]); } 程序运行后的输出结果是()。
A.aegi
B.dfhk
C.abcd
D.abcdefghijk
-
下面程序的运行结果为()。 include void main { char a=’3’: switch(8) { case 3:cout$amp;A.3
B.321
C.31
D.32
-
写出下面程序执行后的运行结果。 include <stdio.h> define N 2 define M N+1 define N
写出下面程序执行后的运行结果。 include <stdio.h> define N 2 define M N+1 define NUM 2*M+1 int main() { int i; for(i=1;i<=num;i++) printf("%d",i); return 0; }>
-
下面程序的运行结果是【】。 include<iostream> using namespace std; void fun(int&a,int b=3)
下面程序的运行结果是【 】。
include <iostream>
using namespace std;
void fun(int &a, int b=3)
{
static int i=2;
a = a + b + i;
i = i + a;
}
int main()
{
int x=5, y=2;
fun(x, y);
cout<<x<<",";
fun(x);
cout<<x<<end1;
return 0;
}
-
下面程序的运行结果为 include<iostream.h> void main() { for(int a=0,x=0;! x&&a<=10;a++) { a++; } cout<<a<<end1; }
A.10
B.11
C.12
D.0
-
下面程序的运行结果是include<iostream.h>void main(){int i=1;while(i<=8)if (i%3!=2)cont
下面程序的运行结果是 include<iostream.h> void main() { int i=1; while(i<=8) if (i%3!=2)continue; else cout<<i; }
A.25
B.36
C.258
D.369
-
下面程序的运行结果为()。 include<iostream.h> voidmain() { chara=3: switch(a) {
下面程序的运行结果为()。 include<iostream.h> voidmain() { chara=3: switch(a) { case3:cout<<"3"; case2:cout<<"2";break; default:cout<<"1"; } }
A.3
B.321
C.31
D.32
-
下面程序的运行结果是()。include<stdio.h>main(){int y=10; do{y--;}while(--y); printf("%d\n"
下面程序的运行结果是()。 include<stdio.h> main() { int y=10; do{y--;}while(--y); printf("%d\n",y--); }
A.-1
B.1
C.8
D.0
-
下面程序的运行结果是()。 include<iostream.h> int fun(int a[],int n) { int resuh=1
下面程序的运行结果是()。 include<iostream.h> int fun(int a[],int n) { int resuh=1; for(inl i=1;i<11;1‘++) result=result * a[i]; retum result; } void main int a[3]={3,4,5}: cout<<fun(a,3)<<endl: }
A.12
B.15
C.20
D.60
-
下列程序输出的结果是()。 include<stdi0.h> funl(chara,charb){charC;c=a;a=b;b=C;) f
下列程序输出的结果是()。 include<stdi0.h> funl(chara,charb){charC;c=a;a=b;b=C;) fun2(char*a,charb){charC;c=*a;*a=b;b=c;) fun3(char*a,char*b){charC;C=*a;*a=*b;*b=C;) voidmain() { chara,b; a=A;b=B;fun1(a,b);putchar(a);putchar(b); a=A;b=B;fun2(&a,b);putchar(a);putchar(b); a=A;b=B;fun3(&a,&b);putchar(a);putchar(b); putchar(\n); }
A.BABBAB
B.ABBBBA
C.ABBABA
D.ABABBA
-
下面程序的运行结果为include<iostream,h>Void swap(int &a,int b){int temp;temp=a++;a=b;
下面程序的运行结果为 include<iostream,h> Void swap(int &a,int b) { int temp; temp=a++; a=b; b=temp; } void main() { int a=2,b=3; swap(a,b); cout <<a <<”,” <<b <<end1 }
A.2,3
B.3,2
C.2,2
D.3,3
-
下面程序段的运行结果是 include<iostream.h> void main() {char*s="abcde"; S+=2;
下面程序段的运行结果是 include<iostream.h> void main() { char*s="abcde"; S+=2; cout<<&s;}
A.cde
B.字符'c'
C.字符'c'的地址
D.无确定的输出结果
-
给出下面程序的运行结果。include<stdio.h>intmain();return0;}
A.6
B.3
C.4
D.5
-
include<stdi.h>main() {intx,y; fr(y=1,x=1;y<=20:y++) {if(x>=8)break; if(x%2==1){x+=5;cntinue;} x-=3; } printf("x=%d,y=%d\n",x,y); } [运行结果]
include<stdi.h>
main()
{intx,y;
fr(y=1,x=1;y<=20:y++)
{if(x>=8)break;
if(x%2==1){x+=5;cntinue;}
x-=3;
}
printf("x=%d,y=%d\n",x,y);
}
[运行结果]
-
下面程序运行后输出的结果为: include int main(); return 0; }
-
下面程序段的运行结果是__________。 include<stdio.h>main(); t ++ ; } }
A.EXAMPLE!
B.example!
C.EXAM
D.example
-
有以下程序: include<stdi0.h> ()
A.1098.0
B.1002,ChangRong,1202.0
C.1001,ChangRong,1098.0
D.1002,ZhangDa,1202.0