A local artist creates and sales large unique art figures based on 3 different shapes: a cube, a torus, and an ellipsoid. The customers pick the shape and pattern for the art piece. The artist needs a program to calculate the handling fee and shipping charge based on the volume of the shape and the total processing charges to create an invoice for her customers. a) The user will enter the desired art shape via a menu option, the name of the customer, and the dimensions of the shape. • Build an appropriate menu for the user that displays the three choices of shapes available with an option to also quit the program. Prompt the user for the desired menu choice. If the menu choice is invalid, display an error message. • Read the dimensions of the desired shape from the user. b) Calculate the volume of the desired shape, the handling fee and the shipping charge based on the volume of the shape. Also, calculate the total processing charge (sum of the handling and shipping). c) Create an invoice that displays the name of the customer, the name of the chosen art shape, the dimension(s) of the shape, the calculated volume to a tenth of a decimal point, the handling fee, the shipping charge, and the total processing charges based on the criteria table on the next page. (Use symbolic constants where appropriate. Use 3.1416 to represent the value of PI.) Formulas used for volume calculations are (see detail illustrations on next page): a. Volume of a cube: side3 b. Volume of a torus: (1/4) ( ) 2 (r + R) (R - r)2 c. Volume of an ellipsoid: (4/3) ( ) (a) (b) (c) Cube Torus Ellipsoid The Handling and Shipping charges are based on the following criteria: Volume (x cubic feet) Handling fee Shipping Charge based on Volume 0 < x 50 100 < x 100 x > 150 $11.25 $0.32 for each cubic foot > 150
Get Answers For Free
Most questions answered within 1 hours.