以下程序的正确运行结果是( )。 #include<iostream.h> int f(int);. void main() { int a=2,i; for(i=0;i<3;i++) cout<<f(a)<<" "; cout<<endl; } int f(int a) { int b=0; static int c=3; b++;c++; return(a+b+c); }
A.777
B.7 10 13
C.79 11
D.7 8 9
[单选题]以下程序的正确运行结果是()。includeint f(int);void main(){int a=2,i;for(i=0;i<以下程序的正确运行结果是( )。 #include<iostream.h> int f(int); void main() { int a=2,i; for(i=0;i<3;i++)cout<<f(a)<<" "; cout<<endl; } int f(int a) { int b=0; static int c=3; b++;c++; return(a+b+c
[单选题]以下程序的正确运行结果是()。includeint fun(int);void main(){int a=2,i;for(i=0;以下程序的正确运行结果是( )。 #include<iostream.h> int fun(int); void main() { int a=2,i; for(i=0;i<3;i++) cout<<fun(a)<<end1; cout<<end1; } int fun(int a) { int b=0; static int c=3; b++;c++; return
[单选题]下列函数的运行结果是includeint f(int a,int B){int c;if(a>b) c=1else if(a=b) c下列函数的运行结果是 #include<iostream.h> int f(int a,int B) {int c; if(a>b) c=1 else if(a=b) c=0; else c=-1; return(c) ;} void main( ) { int i=2,j=3; int p=f(i,j); coutA.-1B.1C.2D.编译出错,无法运行
[单选题]下列函数的运行结果是()。includeint f(int a,int B) {int c;if(a>b)c=1;else if(a=下列函数的运行结果是( )。 #include<iostream.h> int f(int a,int B) { int c; if(a>b)c=1; else if(a==b)c=0; else c=-1; return(c);} void main() {int i=2,j=3; iht p=f(i,j); cout<<p;}A.-1B.1C.2D.编译出错,
[单选题]有以下程序的输出结果是( ) void f(int v , int w) { int t; t=v;v=w;w=t; } main( ) { int x=1,y=3,z=2; if(x>y) f(x,y); else if(y>z) f(y,z); else f(x,z); printf(“%d,%d,%d/n”,x,y,z);}A.1,2,3B.3,1,2C.1,3,2D.2,3,1
[单选题]下列程序的运行结果是()。includeint x=5;int fun(int A) {int C;C=X*a;return C;}v下列程序的运行结果是( )。 #include<iostream.h> int x=5; int fun(int A) { int C; C=X*a; return C; } void main() { int x=3,a=4; x=x+fun(a); cout<<"x="<<x<<endl; }A.x=15B.x=17C.x=23D.x=25
[单选题]下列程序的运行结果是()。includeint x=5;int fun(int a){int c;c=x*a;return c;}vo下列程序的运行结果是( )。 #include<iostream.h> int x=5; int fun(int a) { int c; c=x*a; return c; } void main() { int x=3,a=4; x=x+fun(a); cout<<“x="<<x<<end1; }A.x=15B.x=17C.x=23D.x=25
[单选题]下面程序的运行结果是()。includeint x=5;int fan(int a){int c;c=x*a;return c;}vo下面程序的运行结果是( )。 #include<iostream.h> int x=5; int fan(int a) { int c; c=x*a; return c; } void main() { int x=3,a=4; x=x+fun(a); eout<<"x="<<x<<end1; }A. x=15B.x=17C.x=23D.x=25
[单选题]下面程序的运行结果是()。includeint x=5;int fun(int a){ int c; C=X*a; retum c;}下面程序的运行结果是( )。 #include<iostream.h> int x=5; int fun(int a) { int c; C=X*a; retum c; } void main() { int x=3,a=4; x=x+fun(a); cout<<"x"”<<X<<endl; }A.x=15B.x=17C.x=23D.x=25
[单选题]以下程序的运行结果是include void sub(int x,int y,int *z){*z=y£x;}void main( )以下程序的运行结果是 #include<iostream.h> void sub(int x,int y,int *z) { *z=y-x;} void main( ) { int a,b,c; sub(10,5,&a) ; sub(7,a,&b) ; sub(a,b,&c) ; cout << a <<","<< b <<","