error, try to rename or copy the project to other one, e.g. from Q1 to QIX or QIY.
Questions: (10 marks)
The given files already contain statements to implement a program for managing a Hotel. The structure of the main classes is as follows:
Class Room: contains information about a Room object, including:o code (001, 002, 003, ...)
O status: is 0 (if the Room is empty), or 1 (if there is/are customer(s) in the Room)o size (must be > 0): the maximum number of people renting/using this Room
o price (must be > 0)
Class Node: includes info (a Room object) and next (a pointer for linking).
Class dataList: is a singly linked list that manages regular Nodes with complete information. This class plays the role of managing all Room in the Hotel.
Class requestQueue: is a queue structure (implemented as a linked list), where the component info of the Nodes contains only size (the number of people renting the Room)and price (the expected price, or the maximum money the the customer(s) can pay). Note:size>0 and price>0.
1
Class Hotel: is the main class of the program, containing a dataList used to manage the Room objects and a requestQueue corresponding to a queue of order.
Students are required to carefully read the provided code segments to fully understand the relationships between the classes and the functions within each class. The specific task of the test is to execute the following requirements:
Zoom
+ 93%
Close