In an apartment building some apartments have a one bedroom and the rest have two bedrooms if there are a total of 50 apartments and 80 bedrooms how many apartments have one bedroom and how many have two bedrooms.
Solution.
Let x be the number of apartment with 1 bedroom
Let y be the number of apartment with 2 bedrooms
We then derive the following 2 equations from the problem.
x + y = 50 (1)
x + 2y = 80 (2)
Use equation (1) to solve for x
x + y = 50
x + y - y = 50 - y
x = 50 - y
Replace x into equation (2)
50 - y + 2y = 80
50 + y = 80
50 - 50 + y = 80 - 50
y = 30
x = 50 - y = 50 - 30 = 20
Therefore, 30 apartments have 2 bedrooms and 20 apartments have 1 bedroom.