This time you will be writing three functions to assist in program. The first function is providedfloatcube(floatnumber){returnnumber * number * number;}floatcalcVolume(floatradius){//Your code...



This time you will be writing three functions to assist in program. The first function is provided







float



cube

(

float

number){





return

number * number * number;



}







float



calcVolume

(

float

radius){





//Your code here





}







// Hint to convert from cubic inches you divide cubic inches by 12^3





float



convertToCubicFt

(

float

number){





//Your code here





}







//Diameters in inches




int snowmanDiameter[
6
] = {
80
,
46
,
35
,
24
,
20
,
10
};







Formula for the Volume of a Sphere




sphere_volume



Pi = 3.14(This is sufficient precision)



R = Radius or 1/2 of the Diameter



You need to use a
for
loop to calculate your total.




Approximate Output




(Your answer will be exact)




Approx
200
cubic feet


Oct 05, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here