Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The engineering division wants to have a functionality to deal with geometric 2D and 3D shapes. The user can choose to enter the measurements with

The engineering division wants to have a functionality to deal with geometric 2D and 3D shapes. The user can choose to enter the measurements with different metric or imperial units and choose the conversion required. The needed units are as follows: Imperial units Metric units Inch (in) Centimeter (cm) Foot (ft) Decimeter (dm) Yard (yd) Meter (m) Mile (mi) Kilometer (km)

For the geometric plane figures, the functions calculate the area and the perimeter according to measurement unit and the chosen conversion unit. On the other hand, the engineering division likes the program to calculate the volume and surface area of the geometric solids as well. There should be a function for each figure and solid listed in the table. The function receives the required measurements in specified units and returns the results in the units as designated by the user. For example, the function calculateSquare takes the side as an argument and returns the area and the circumference. Likewise, the function calculateCylinder takes the arguments radios and height and returns surface area (surfaceArea) and volume. 2D figured Argument(s) instructions (if any)

3D solids Argument(s) instructions (if any)

Scalene triangle sides, not base and height Triangular Pyramid Isosceles triangle sides, not base and height Cube Equilateral triangle sides, not base and height Square Pyramid Right Triangle leg a and leg b Cone Right Triangle leg a and Hypotenuse c Cylinder

The values are calculated to the nearest 100th of the unit. The units of calculation and conversion should be determined by the user and the calculation should be done to the second decimal place. Use case scenario: The program displays a welcome screen including the name of the company, the name of the division, the name of the program, and the names and IDs of the programming team members. It also prompts the user to choose what calculation he/she wants to pursue, i.e., 2D figures or 3D solids. After that, the program allows the user to specify the figure/solid type, the measurement unit, and the conversion unit (It repeats for all figures/and solids according to the user selection of number of solids/figures). The user may enter the same unit for the measurement and conversion if no conversion is required, i.e. the user enters cm for measurement units and cm for conversion units. After that, the user enters the measurements of each figure/solid as

instructed by the program. For each figure the program displays its original measurements in original unit and its calculated quantities in the original and conversion units. After each run the program prompts the user to choose to terminate the program or continue in new calculation. If the user chose to terminate, the program displays a thank you screen.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

Explain employment branding.

Answered: 1 week ago