The amount one person will pay for a day is $4
The amount two people will pay for a day is $8
The amount Beth paid for 3 days is 4*3=12
The amount Maria paid for 3days is also 4*3=12
So to find the amount they will pay for 3days, add 12 and 12 to get 24.
The girls will pay $24 for the 3days.
Hope it helps