Please check below for a sample output. Scenario 1: Please enter the name for your hotel: Ben Welcome to Ben hotel maker, please select the room you would like to have in your hotel. 1: Single Room $50 2: Double Room $80 3: Deluxe Room $100 4: Done, go to reservation 1 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 1 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 4 Welcome to Ben hotel maker, please select the room you would like to have in your hotel. 1: Single Room $50 2: Double Room $80 3: Deluxe Room $100 4: Done, go to reservation 2 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 2 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 3 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 4 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 2 Sorry you already have this feature. What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 4 Welcome to Ben hotel maker, please select the room you would like to have in you hotel. 1: Single Room $50 2: Double Room $80 3: Deluxe Room $100 4: Done, go to reservation 4 Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=false, Type=Double Room + Netflix access, Price=100, isReserved?=false, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price =170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue 1 Reservation successful Current rooms status: [ Type=Single Room + View, Price=100, isReserved?=true, Type=Double Room + Netflix access, Price =100, isReserved?=false, Type=Double Room + View + Netflix access, Price =150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue 1 The room is not available Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=true, Type=Double Room + Netflix access, Price=100, isReserved?=false, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue Reservation successful Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=true, Type=Double Room + Netflix access, Price=100, isReserved?=true, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue Reservation successful Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=true, Type=Double Room + Netflix access, Price=100, isReserved?=true, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=true ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue Hotel revenue: 370 \begin{tabular}{|c|} \hline RoomFactory \\ \hline +generateRoom(RoomType):Room \\ \hline \end{tabular} \begin{tabular}{|l|} \hline \multicolumn{1}{|c|}{ «interface>>Room } \\ \hline +getPrice():int \\ +getDescription():String \\ +getReservationStatus():boolean \\ +reserveTheRoom(RoomType):boolean \\ \hline \end{tabular} \begin{tabular}{|l|} \hline WithView \\ \hline \\ \hline \end{tabular} \begin{tabular}{|l|} \hline WithNetflixAccess \\ \hline \\ \hline \end{tabular}
Please check below for a sample output. Scenario 1: Please enter the name for your hotel: Ben Welcome to Ben hotel maker, please select the room you would like to have in your hotel. 1: Single Room $50 2: Double Room $80 3: Deluxe Room $100 4: Done, go to reservation 1 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 1 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 4 Welcome to Ben hotel maker, please select the room you would like to have in your hotel. 1: Single Room $50 2: Double Room $80 3: Deluxe Room $100 4: Done, go to reservation 2 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 2 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 3 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 4 What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 2 Sorry you already have this feature. What feature the room has? 1: With view $50 2: With Netflix access $20 3: Nothing 4: Done 4 Welcome to Ben hotel maker, please select the room you would like to have in you hotel. 1: Single Room $50 2: Double Room $80 3: Deluxe Room $100 4: Done, go to reservation 4 Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=false, Type=Double Room + Netflix access, Price=100, isReserved?=false, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price =170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue 1 Reservation successful Current rooms status: [ Type=Single Room + View, Price=100, isReserved?=true, Type=Double Room + Netflix access, Price =100, isReserved?=false, Type=Double Room + View + Netflix access, Price =150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue 1 The room is not available Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=true, Type=Double Room + Netflix access, Price=100, isReserved?=false, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue Reservation successful Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=true, Type=Double Room + Netflix access, Price=100, isReserved?=true, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=false ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue Reservation successful Current rooms status: [ Type=Single Room + View, Price =100, isReserved?=true, Type=Double Room + Netflix access, Price=100, isReserved?=true, Type=Double Room + View + Netflix access, Price=150, isReserved?=false, Type=Deluxe Room + View + Netflix access, Price=170, isReserved?=true ] Hi customer, what room would you like?: 1: Single Room 2: Double Room 3: Deluxe Room 4: Done, show hotel revenue Hotel revenue: 370 \begin{tabular}{|c|} \hline RoomFactory \\ \hline +generateRoom(RoomType):Room \\ \hline \end{tabular} \begin{tabular}{|l|} \hline \multicolumn{1}{|c|}{ «interface>>Room } \\ \hline +getPrice():int \\ +getDescription():String \\ +getReservationStatus():boolean \\ +reserveTheRoom(RoomType):boolean \\ \hline \end{tabular} \begin{tabular}{|l|} \hline WithView \\ \hline \\ \hline \end{tabular} \begin{tabular}{|l|} \hline WithNetflixAccess \\ \hline \\ \hline \end{tabular}

Trending now
This is a popular solution!
Step by step
Solved in 4 steps with 6 images









