27.9k views
4 votes
For this lab you will find the area of an irregularly shaped room with the shape as shown above.

Ask the user to enter the values for sides A, B, C, D, and E and print out the total room area.


Remember the formula for finding the area of a rectangle is length * width and the area of a right triangle is 0.5 * the base * height.


Please note the final area should be in decimal format.


Sample run:


Enter side A: 11

Enter side B: 2

Enter side C: 4

Enter side D: 7

Enter side E: 1

Output:


Room Area: 53.5

User Cyberconte
by
4.9k points

2 Answers

5 votes

Answer:

4.4583333333333

(decimal)

4.4583333333333 x 100

(scientific notation)

107

24

(fraction)

Explanation: i hope i helped you bye bye :3

User Nigel Thomas
by
5.3k points
6 votes

Answer:

A=int(input("Enter side A: "))

B=int(input("Enter side B: "))

C=int(input("Enter side C: "))

D=int(input("Enter side D: "))

E=int(input("Enter side E: "))

R= A*B

b=A-C

T=1/2*E*b

s=D-(B+E)

S=s*b

TA=S+T+R

print("Room Area: "+ str(TA))

Step-by-step explanation:

Hope this helps anyone struggling :)

User Johan Soderberg
by
4.9k points