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

What is 19% of 26, What is 19% of 26? To ?nd out 19% of 26, multiply 26...

What is 19% of 26? To ?nd out 19% of 26, multiply 26 through the decimal equivalent of 19% (0.19); 26 × 0.19 = 4.94.

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

Horizontal asymptote, The horizontal asymptote of (16x+7)(x^2-5)/(x^2+36).

The horizontal asymptote of (16x+7)(x^2-5)/(x^2+36).

Expected value, Expected Value For taking decisions under conditions of...

Expected Value For taking decisions under conditions of uncertainty, the concept of expected value of a random variable is used. The expected value is the mean of a probability

What would this expression simplify to, If 3x2 is multiplied by the quantit...

If 3x2 is multiplied by the quantity 2x3y raised to the fourth power, what would this expression simplify to? The statement in the question would translate to 3x 2 (2x 3 y) 4 .

Evaluate the area of circle, If the radius of a sphere is doubled, the surf...

If the radius of a sphere is doubled, the surface area is a. multiplied by 4. b. multiplied by 2. c. multiplied by 3. d. multiplied by 8. a. The formula for the surf

Wavy curve method, In order to compute the inequalities of the form ...

In order to compute the inequalities of the form   where n 1 , n 2 , ....... , n k , m 1 , m 2 , ....... , m p are natural and real numbers and a 1 , a 2 , ... , a k ,

Show that the height of the opposite house, From a window x meters hi...

From a window x meters high above the ground in a street, the angles of elevation and depression of the top and the foot of the other house on the opposite side of the street  are

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