Question: Your task is to create a program that lets students reserve a room in the building, finish using a room ( i . e .
Your task is to create a program that lets students reserve a room in the building, finish using a room ie mark it available check the status of a room, and see all of the rooms in the building regardless of availability
Show the user a main menu with five options: Reserve a room. Finish using a room ie mark it as available Check the status of a room. View all rooms in the building, regardless of availability. Exit.
The user can go through options as many times as they want until they choose to exit. If they choose to reserve a room Ask which room they would like to reserve. Pass in the appropriate status variable to the reserveroom function and store the result in the same status variable. For example, if the user wants to reserve the auditorium, the function call line would be auditoriumstatus reserveroomauditoriumstatus
The reserveroom function should print a confirmation message and return booked as a string. If they choose to finish using a room Ask which room they finished using. Pass in the appropriate status variable to the donewithroom function and store the result in the same status variable. For example, if the user wants to finish using the auditorium, the function call line would be auditoriumstatus donewithroomauditoriumstatus
The donewithroom function should print a confirmation message and return available as a string. If they choose to check the status of a room Ask which room they would like to check. Pass in the appropriate status variable to the checkroomstatus function. Use the return value directly in a print in main. For example, if the user wants to check the auditorium, the function call line would be printcheckroomstatusauditoriumstatus
The checkroomstatus function should return a string stating whether the room is available or booked, based on the status that was passed in If they choose to view all rooms Use a for loop to print each room in the listofrooms list. If they choose to exit Print a short thank you message and let the program end.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
