the volume of a pyramid, Mathematics

Assignment Help:

Write a script to determine the volume of a pyramid, which is 1/3 * base * height, where the base is length * width.  On time the user to enter values for the length, width, and the height and then determine the volume of the pyramid.  When the user enters every value, they will then be prompted also for either 'i' for inches, or 'c' for centimeters. (Note 2.54 cm = 1 inch).  Your script should print the volume in cubic inches with 3 decimal places.  As an instance, the output might look like this:

 

This script will calculate the volume of a pyramid.

Enter the length of the base: 50

Is that i or c? i

Enter the width of the base: 6

Is that i or c? c

Enter the height: 4

Is that i or c? i

The volume of the pyramid is xxx.xxx cubic inches.

 


Related Discussions:- the volume of a pyramid

Tangents, find a common tangent to two circles

find a common tangent to two circles

What''s my balance, I should have an account balance for $50.96. You took o...

I should have an account balance for $50.96. You took out $50.96 for a product on 6/18 which was NOT downloaded or delivered as it not available in the time frame I needed it. I am

Ratio, There are only Chinese and Malay pupils in a hall.The ratio of the n...

There are only Chinese and Malay pupils in a hall.The ratio of the number of boys to the number of girls is 2:3.The ratio of the number of Chinese boys to the number of Malay boys

BIOMATH, Ask quHarvesting prevents the population size of a species from at...

Ask quHarvesting prevents the population size of a species from attaining its natural carrying capacity. We can add harvesting to the logistic model by assuming that the per capita

Product moment coefficient, Product Moment Coefficient This gives an i...

Product Moment Coefficient This gives an indication of the strength of the linear relationship among two variables. Note that this formula can be rearranged to have di

Functions, find the derived functions

find the derived functions

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd