早教吧作业答案频道 -->其他-->
圆球的体积?看看我的程序对吗?C语言的知道了圆球的半径,求体积#define PI 3.14159#includevoid main(){ double r,s;printf("Piease input r:");scanf("%f",&r);s=(4/3)*PI*r*r*r;printf("s=%f",s);}
题目详情
圆球的体积?看看我的程序对吗?C语言的
知道了圆球的半径,求体积
#define PI 3.14159
#include
void main()
{ double r,s;
printf("Piease input r:");
scanf("%f",&r);
s=(4/3)*PI*r*r*r;
printf("s=%f",s);
}
知道了圆球的半径,求体积
#define PI 3.14159
#include
void main()
{ double r,s;
printf("Piease input r:");
scanf("%f",&r);
s=(4/3)*PI*r*r*r;
printf("s=%f",s);
}
▼优质解答
答案和解析
#define PI 3.14159
#include
void main()
{ double r,s; //将此处的double改成float型
printf("Piease input r:");
scanf("%f",&r);
s=(4/3)*PI*r*r*r; //将此处4/3改写成4.0/3.0
printf("s=%f",s);
}
#include
void main()
{ double r,s; //将此处的double改成float型
printf("Piease input r:");
scanf("%f",&r);
s=(4/3)*PI*r*r*r; //将此处4/3改写成4.0/3.0
printf("s=%f",s);
}
看了 圆球的体积?看看我的程序对吗...的网友还看了以下:
会做的来解决看,看看你有多厉害、、、、已知定义域为R的函数f(x)在8到正无穷上是减函数,且函数y 2020-04-26 …
已知函数f(x)定义在R上,对∀x,y∈R,有f(x+y)+f(x-y)=2f(x)•f(y),且 2020-05-13 …
matlab matlabc=40r=120a=96o=20y=3(角度)f=0.2[x]=sol 2020-05-16 …
定义在R上的函数f(x)对任意a,b∈R都有f(a+b)=f(a)+f(b)+k(k为常数).(I 2020-06-02 …
映射题,求正解.首先我读不懂题(f(n)∈R,v∈R,u∈R)求所有的f:R→R满足:(1)f(2 2020-06-07 …
分析并写出下面程序的输入输出的形式#includeMain(){Floata,b,c,r;Scan 2020-07-23 …
已知函数f(x)满足f(x+y)+f(x-y)=2f(x)×f(y).(x∈R,y∈R.),且f( 2020-07-27 …
定义在R上的函数f(x)对任意x,y∈R,都有f(x+y)=f(x)+f(y)-1定义在R上的函数 2020-08-01 …
试求出所有的函数f:R→R,使得对于任何的x,y∈R,都有f(x^2+y^2)=xf(x)+yf(y 2020-10-31 …
设函数f(x)=x^2+ax+bcosx(a,b∈R),集合A={x∣f(x)=0,x∈R},B={ 2020-11-01 …