Answered step by step
Verified Expert Solution
Question
1 Approved Answer
#### Q 2 d ( 1 0 marks ) The restaurant has decided to allow larger bookings. This is implemented by allowing multiple bookings under
#### Qd marks
The restaurant has decided to allow larger bookings. This is implemented by allowing multiple bookings under a single name, each booking being for a single table of up to four patrons. Tables are configured such that two tables seats patrons, three tables seats and so on If Howson was to book for a party of they would make two bookings. Each additional booking made would have the next available reservation ID after the one provided, so if Howson was booked under reservation ID there would be a booking for reservation ID and a booking for reservation ID if was available. If Linson has already booked under reservation ID then Howson would have and It can be assumed that the initial reservation ID is available. When large bookings are made, patrons are not allowed to book a particular table number.
The code below extends the BookingsExtended class. Amend the addlargebooking method to enable a booking of any party size to be added, with one table being booked per four party members. Any remaining party members would have a final table booked.
You can use the tests below to help check if your code is working. NOTE that failing the tests is a clear indication you code is faulty, but passing the tests is NOT a guarantee it is correct. Your tutor may run additional tests.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started