Question: This program is written in Java, any help would be greatly appreciated. We want you to create a class RoomPeople that can be used to
This program is written in Java, any help would be greatly appreciated.

We want you to create a class RoomPeople that can be used to record the number of people in the rooms of a building. The class has the attributes: numberlnRoom -the number of people in a room totalNumber - the total number of people in all rooms as a static variable The class has the following methods: addOneToRoom - adds a person to the room and increases the value of totalNumber removeOneF romRoom - removes a person from the room, ensuring that numberlnRoom does not go below zero, and decreases the value of totalNumber as needed get Number - returns the number of people in the room getTotal - a static method that returns the total number of people Please write a program to test the class RoomPeople. Expected results
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
