Question: 1 . Using the same room capacities listed in question 1 , consider the following Python statement. if ( size < = 2 0 )

1. Using the same room capacities listed in question 1, consider the following Python statement.
if (size <=20):
print("choose room E")
elif (size <=50):
print("choose room D")
elif (size <=200):
print("choose room C")
elif (size <=500):
print("choose room B")
elif (size <=1000):
print("choose room A")
Does this code always give the expected answer? In other words, is the room selection made by the algorithm always correct for all values between 0 and 1000 inclusive?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!