下列程序输出的结果是()。include void f(int * x ){ *x = 10 ;
下列程序输出的结果是()。include void f(int * x ){ *x = 10 ; }void main(){ int a,*p=&a; f(p); printf("%d",++(*p));}提示:指针x指与指针p指向同一个变量,10赋给指针x所指的地址上的内容,++(*p)是指指针p所指地址上内容++。
A 输出的值是随机值
B 因输出语句错误而不能执行者
C 输出值为10
D 输出值为11
时间:2024-04-05 13:21:24
相似题目
-
下面程序段的运行结果是( )注意输出结果的格式#include void main(){char *p=”abcdefgh”;p+=3;printf(%s\n,p);}
-
下面程序的输出结果是______。 #include void main() { int n=9; while(n > 6){n--; printf(%d,n);} }
-
以下程序的输出结果是( ) #include iostream.h #include string.h void main() { char *p[10]={abc,aabdfg,dcdbe,abbd,cd}; cout<
-
以下程序运行后的输出结果是#include“stdio.h”void main(){ char c;c='B'+32;printf(%c\n,m);}
-
有下列程序 #include void main() { int a=0,b=0,c=0; if (++a || ++b && ++c) printf('%d,%d,%d', a, b, c); } 程序执行后的输出结果是________。
-
10.下面程序的输出结果是#include void increment(void);int main(void){increment(); increment(); increment();return 0;}void increment(void){int x = 0;x += 1;printf(\%d \, x);}
-
有以下程序: include <stdio.h> void f(); } 执行后的输出结果【 】。
-
以下程序的输出结果是()。include <iostream.h>void main(){int a=0,i;for(i=1 ;i<5;i++){ switc
以下程序的输出结果是()。include <iostream.h>void main(){ int a=0,i; for(i=1 ;i<5;i++) { switch(i) { case 0: case 3: a+ =2; case 1: case 2: a+ =3; default: a+ =5; } } cout<<a<<end1; return;}
A.31
B.13
C.10
D.20
-
下列程序的输出结果是inClUde<iostream.h>iht b=2;int funC (int*a) { b+=*a;return(b);}void m
下列程序的输出结果是 inClUde<iostream.h> iht b=2; int funC (int*a) { b+=*a;return(b);} void main() { inta=2,res=2; res+=func(&a); cout<<res;}
A.4
B.6
C.8
D.10
-
以下程序的输出结果是(44)。 include""void main(){ printf("%d\n",NULL);}A.不确定的值B.0C.-1
以下程序的输出结果是(44)。 include"" void main(){ printf("%d\n",NULL);}
A.不确定的值
B.0
C.-1
D.1
-
下列程序段的输出结果是include<iostream.h>void fun(int*x,int*y){cout<<*x<<*y;*X=3;*y=4;}vo
下列程序段的输出结果是 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
-
下列程序的输出结果是()。include<stdio.h>void main(){ int a=0,b=1,c=2;if(a>0‖++b>0)++C;printf("%d,%d,%d",a,b,C) ;}
A.0,1,2
B.1,2,3
C.1,1,3
D.1,2,2
-
下列程序的输出结果是()。 include<stdio.h> void main() { int b[6]={2,4,6,8,10,12}; int*p--b,**q=&p; printf("%d",*(p++)); printf("%d",**q); }
A.*p=&a;scanf("%1f",p);
B.*p=&a;scanf("%f",p);
C.p=&a;scanf("%1f",*p);
D.p=&a;scanf("%1f",p);
-
以下程序段的输出结果是[ ]。 include<iostream.h> void ref(int &i); void main(){int val=1
以下程序段的输出结果是 [ ] 。
include<iostream.h>
void ref(int &i);
void main(){
int val=1;
cout<<“旧值:”<<val<<end1;
ref(val);
cout<<”新值:”<<val<<end1;
}
void ref(int &i){i=10;}
-
下述程序的输出结果是()。include<stdio.h> void main{ int b[6]={2,4,6,8,10,12);int*p=
下述程序的输出结果是()。
include<stdio.h>
void main
{ int b[6]={2,4,6,8,10,12);
int*p=b,**q=&p;
printf("%d,",*(p++));
printf("%d,",**q);
}
A.4,4
B.2,2
C.4,5
D.2,4
-
要求下面的程序运行后,显示如下结果: 2 10 4 6 1 5 2 3 2 4 7 8 5 1 3 2 下列程序执行后的输出结果是________。 include void main(); }
A.2,0
B.1,4
C.2,1
D.0,3
-
阅读以下程序,写出程序运行后的输出结果是 ______。include<iostream.h>void main(){char a[]={'
阅读以下程序,写出程序运行后的输出结果是 ______。 include<iostream.h> void main(){ char a[]={'H','e','1','1','o','\0'}; int i,j; i=sizeof(a)/sizeof(char); j=strlen(a) cout<<i<<‘ ’<<j;
A.6 6
B.5 6
C.1 5
D.6 5
-
以下程序的输出结果是 ______。include<iostream.h>void main() {char w[][10]={ "ABC", "DEFGH"
以下程序的输出结果是 ______。 include<iostream.h> void main() { char w[][10]={ "ABC", "DEFGH", "IJKL" , "MNOP" }; int k; for (k=1 ;k<3 ;k++) cout<<w[k]<< " " }
A.ABC FGH KL
B.ABC EFG IJ M
C.EFG JK 0
D.DEFGH IJKL
-
执行下述程序后,输出的结果是()。 include<stdio.h> define S(X)X*X void main { int
执行下述程序后,输出的结果是()。 include<stdio.h> define S(X)X*X void main { int a=9,k=3,m=2; a/=S(k+m)/s(k+m); printf("%d",a); }
A.1
B.4
C.9
D.0
-
下列程序的输出结果为()。 include<iostream.h> void main { char*a[]={”hell0”,”the”,”
下列程序的输出结果为()。 include<iostream.h> void main { char*a[]={”hell0”,”the”,”world”}; char** pa = a: pa++; cout<<*pa<<endl: }
A.hello
B.the
C.world
D.hellotheworld
-
下面的程序输出结果是()。include<iostream>using namespace std;void add(){static int x;x++;c
下面的程序输出结果是()。 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> void main(){double d=3.2;intx,y:x=1.2;y=(x+3.
下列程序的输出结果是()。 include< iostream.h> void main() {double d=3.2; intx, y: x=1.2; y=(x+3.8)/5.0 cout<<y*d <<endl;}
A.3
B.3.2
C.0
D.3.07
-
有以下程序 include<stdio.h>include<string.h>void fun(); } 程序运行后的输出结果是
A.012345
B.876543210
C.876543
D.012345678
-
以下程序若运行时输入ABC,则输出结果是______。 include include void main(); }
A.ABC6789
B.ABC67
C.12345ABC6
D.ABC45678