Question: Student question Create a class Hotel with the following elements: Instance variables: int numberRooms, int numberGuests, boolean isAvailable: Seters for all Maximum of guests allowed
Student question
Create a class Hotel with the following elements:
Instance variables: int numberRooms, int numberGuests, boolean isAvailable: Seters for all
Maximum of guests allowed is and maximum number of rooms is execu diamond on trace: "Sta diamond bloc ini diamond alizer".
One ini alizer block to set the default number of guests to default number of rooms to and the isAvailable flag to True. Print execu diamond. trace: "Block inisalizer
Constructor with parameters: validates the number of guests and rooms to be in the range max no of rooms and the number of guests in the range max no of guests Use stac valida on func
Exit
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
