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

Mean deviation, is that formula of sample and population for mean deviation...

is that formula of sample and population for mean deviation is the same?

Set theory, how to prove Decidability Theorem of Logic

how to prove Decidability Theorem of Logic

Quantitative, The Laser Computer Printer Company decides monthly what to pr...

The Laser Computer Printer Company decides monthly what to produce during the subsequent month. They produce three types of printers, the Laser Rocket, the Alpha Laser, and the La

Graph all four vectors on similar axis system, The vector a → =(2,4) compu...

The vector a → =(2,4) compute 3a → , ½ a → and -2a → . Graph all four vectors on similar axis system. Solution: Now here are the three scalar Multiplication 3a → = (6,

Correlation and regression, Correlation and Regression Correlation ...

Correlation and Regression Correlation CORRELATION is an important statistical concept which refers to association or interrelationship among variables. The reasons of

What are the characteristics of a queuing system, What are the characterist...

What are the characteristics of a queuing system?  (i) The input pattern  (ii) The queue discipline  (iii) The service mechanism

Calculate zeros in the denominator of rational expressions, About Zeros in ...

About Zeros in the Denominator of Rational Expressions One thing that you must be careful about when working with rational expressions is that the denominator can never be zero

Compound interest, Ask question #Minimum 100 words accMick invested $5516 i...

Ask question #Minimum 100 words accMick invested $5516 in an account at 14% compounded quarterly. Calculate the total investment after 1 years.

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