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

题目内容 (请给出正确答案)
下列程序的招待结果是【 】。 include float temp;float & fn2(float r){ temp=r*

下列程序的招待结果是【 】。

include <iostream. h>

float temp;

float & fn2(float r)

{

temp=r* r* 3.14;

return temp;

}

void main( )

{

float a=fn2(5.0);

float& b=fn2(5.0)

b=20;

cout<<temp<<end1;

}


参考答案

更多 “ 下列程序的招待结果是【 】。 include float temp;float fn2(float r){ temp=r* 下列程序的招待结果是【 】。include <iostream. h>float temp;float fn2(float r){temp=r* r* 3.14;return temp;}void main( ){float a=fn2(5.0);float b=fn2(5.0)b=20;cout<<temp<<end1;} ” 相关考题
考题 下列程序的执行结果是______。 include float temp; floatfn2(float r) { temp= 下列程序的执行结果是______。include<iostream.h>float temp;floatfn2(float r){temp=r*r*3.14;return temp;}void main( ){float a=fn2(5.0);floatb=fn2(5.0);b=20;cout<<temp<<endl;}

考题 有以下程序includevoid fun(float* p1,int n1,float,*p2,int n2,float* s){ int i;s=( 有以下程序 #include<stdio.h> void fun(float * p1,int n1,float,*p2,int n2,float * s) { int i; s=(float *)calloc(1,sizeof(float)); *s=0; for(i=0;i<n1;i++) *s+=*p1++; for(i=0;i<n2;i++) *s+=*p2++; } main() { float a[2]={1.1,2.2},b[3]={10.0,20.0,30.0),*s=a; fun(a,2,b,3,s); printf("%f\n",*s); } 上面程序的输出结果是( )A.60B.3.3C.63.3D.1.1

考题 以下程序的输出结果是 void fun(float*p1,float*p2,float*s) { s=(float*)calloc(1,sizeof(float)); *s=*p1+*p2++;} main() { float a[2]={1.1,2.2},b[2]={10.0,20.0},*s=a; fun(a,b,s); printf("%5.2f\n",*s);}A.11.1B.12C.21.1D.1.1

考题 下面4个选项中,均是不合法的用户标识符的是()。A.P_0,DoB.float,lao,_AC._123,temp,INTD.a-b,3_p3,char

考题 写出以下程序的运行结果: int main() { int p,r,n=4,m=7,temp; if(n<m) {temp=n;n=m;m=temp;} p=n*m; while(m!=0) {r=n%m; n=m; m=r; } printf(“%d,%d”,n,p/n); return 0; }

考题 8、下列关于float描述错误的是A.float:leftB.float-centerC.float:rightD.float:none

考题 00330038003000301585067361821下列程序段执行结果是___________。 x = 1 print(type(x)) x = 1.0 print(type(x)) x = '1.0' print(type(x)A.<class 'int'> <class 'float'> <class 'str'>B.<class 'float'> <class 'int'> <class 'str'>C.<class 'str'> <class 'float'> <class 'int'>D.<class 'str'> <class 'int'> <class 'float'>

考题 下列程序段执行结果是___________。 x = 1 print(type(x)) x = 1.0 print(type(x)) x = '1.0' print(type(x)A.<class 'int'> <class 'float'> <class 'str'>B.<class 'float'> <class 'int'> <class 'str'>C.<class 'str'> <class 'float'> <class 'int'>D.<class 'str'> <class 'int'> <class 'float'>

考题 使用scanf函数需要在头文件中添加___.A.#include <stdio.h>B.#include <ctype.h>C.#include <float.h>D.include <iomanip.h>