First things first, we have to find the number of people who share a room when there is 5 people to find how much the room would cost.
First multiply 36 by 5.
36 x 5 = 180
Now that we know that the total amount of the room costs 180 we need to divide that by 8 to see how much each person would end up paying if 8 people shared a room.
180 / 8 = 22.50
So the amount each person would pay is $22.50 if 8 people shared a room.