Question: 8. A quadrilateral is a polygon with 4 sides. We want to create a java program that identifies any type of quadrilateral and calculates it


8. A quadrilateral is a polygon with 4 sides. We want to create a java program that identifies any type of quadrilateral and calculates it area. The following describe the different types of quadrilaterals: Rectangle and Square have the same characteristic Al=90 and A3=90 L1 A1 A2 L4 L2 A4 A3 L3 o The Square has L1=L2 but the rectangle has L1 L2. o The area of rectangle = L1*L2 o The area of square=L1*L1 In the case that the quadrilateral is not rectangle and not a square, we have the follows forms: o The Parallelogram has Ll=L3 and L2=L4 and Al=A3 and A2=A4. The area = L3*h . o The Rhombus is a Parallelogram having L1=L2=L3=L4. The area = L3*h L1 A2 A1 L4 L2 I A4 A3 L3 o If case that the form is not a Parallelogram and not Rhombus, the form is a Trapezoid. The are of a Trapezoid=h* (L1+L3)/2 L1 L4 h L2 L3
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
