成人AV在线无码|婷婷五月激情色,|伊人加勒比二三四区|国产一区激情都市|亚洲AV无码电影|日av韩av无码|天堂在线亚洲Av|无码一区二区影院|成人无码毛片AV|超碰在线看中文字幕

java 編寫程序求圓柱體的體積和圓的周長?

編寫程序求圓柱體的體積和圓的周長?內(nèi)容如下:#include<stdio。H>void main(){float R,C,Sprintf(“please input the radius of

編寫程序求圓柱體的體積和圓的周長?

內(nèi)容如下:

#include<stdio。H>

void main()

{

float R,C,S

printf(“please input the radius of the circle:”)

scanf(%f“,&r)/*用于輸入浮點(diǎn)數(shù)據(jù)并將其存儲在地址中&R*/

C=2*3.1415926*R/*用于計算周長,并將其賦給c*/

s=3.1415926*r*r/*以計算面積*/

v=4/3*pi*r*r*r/*用于計算體積*/

printf(“周長c=%8.4f;\n面積s=%8.4f;\n體積v=%8.4f”,c,s,v)/*周長、面積、體積為8個字符寬,小數(shù)點(diǎn)后4位*/

擴(kuò)展數(shù)據(jù):

圓周長公式:C=2πR

圓面積公式:S=πR^2

球體積公式:v=3/4*πR^3