trapazoid area

Program Description This program will calculate the area of a trapezoid. The program will ask the user to enter the two bases and height and then use these values to calculate and then print the area of the trapezoid. The design step will include pseudocode.

Analysis I will use sequential programming statements. I will define three float numbers for the two bases and the height: baseA, baseB, height. Float numbers were selected as opposed to integers to make sure trapezoids of all dimensions are possible and not just whole numbers. Float number will store the area: area The area will be calculated by this formula: Area = ½ * (baseA + baseB) * height For example if the bases are 4.7 and 2.1, and the height is 5.3 the area is calculated as: Area = ½ * (4.7 + 2.1) * 5.3 = ½ * 6.8 * 5.3 = 3.4 * 5.3 = 18.02

"Order a similar paper and get 100% plagiarism free, professional written paper now!"

Order Now