Question: Exercise: (Rectangular Prism Calculator) Write a program to calculate the surface area and volume of a rectangular prism and a capsule shape. Once, the user
Exercise: (Rectangular Prism Calculator) Write a program to calculate the surface area and volume of a rectangular prism and a capsule shape. Once, the user has entered the following input: length (), width (w) and height (h) for the rectangular prism radius (r) and side length (a) for the capsule It will display the results in a formatted text output. Please it is important to declare all variables with the appropriate data type. Use the following formulas: Capsule Volume-tr(43)r + a) Surface Area 2?r(2r + a) Rectangular Prism Volume = Iwh Surface Area 2(1w+lh + wh)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
