the volume of a pyramid, Mathematics

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.

 

Posted Date: 3/20/2013 1:08:52 AM | Location : United States







Related Discussions:- the volume of a pyramid, Assignment Help, Ask Question on the volume of a pyramid, Get Answer, Expert's Help, the volume of a pyramid Discussions

Write discussion on the volume of a pyramid
Your posts are moderated
Related Questions
The Geometric Index or Industrial Share index The Geometric Index or Industrial Share index is an index of 30 selected top industrial companies. This is calculated by taking a


It’s been a busy weekend for Larry. Five people in his neighborhood left on vacation Saturday morning and each of them left a pet for Larry to care for until they return. It’s a go

The positive value of k for which x 2 +Kx +64 = 0 & x 2 - 8x + k = 0 will have real roots . Ans: x 2 + K x + 64 = 0 ⇒  b 2 -4ac > 0 K 2 - 256 > 0 K

How do you calculate for the distance between two co-ordinates?

If the expression 9y - 5 represents a certain number, which of the following could NOT be the translation? a. five less than nine times y b. five less than the sum of 9 and y c




I need marketing management sample assignment as a guide