Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Python Programming Question 2 (a) A school library has 3 study rooms available for students to book during its opening hours, on a first-come-first-serve basis.

Python Programming

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

Question 2 (a) A school library has 3 study rooms available for students to book during its opening hours, on a first-come-first-serve basis. Assume there is no pre-booking, that is, the study rooms can be booked only on the day of usage itself. A library staff should be able to select to perform one of the following actions: Book a room o If there is no available room, the message: No study room available currently is displayed and the action of booking a room is terminated. o If there is at least one room available: - The case where only one room left: Inform the student this is the only room number left and asks if the student wishes to proceed. If student chooses not to proceed. terminate the action of booking a room. -The case where there is more than one available room: List the unoccupied room numbers in ascending order and allow the student to make a choice

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Linked Data A Geographic Perspective

Authors: Glen Hart, Catherine Dolbear

1st Edition

1000218910, 9781000218916

More Books

Students also viewed these Databases questions