Variables
• p: number of pizza slices purchased
,
• s: number of sodas purchased
,
• t: total cost
Given that there are 8 students and each student receives 2 slices of pizza, then:
[tex]p=8(2)=16[/tex]
That is, they have to purchase 16 slices of pizza.
Given that there are 8 students and each student receives one can of soda, then:
[tex]s=8(1)=8[/tex]
That is, they have to purchase 8 cans of soda.
If 1 can of soda costs $1.50, then, s cans of soda will cost 1.5s dollars
If 1 slice of pizza costs $3, then, p slices will cost 3p dollars
The total cost is the addition of the cost of sodas and the cost of pizza, then:
[tex]3p+1.5s=t[/tex]
Substituting p = 16 and s = 8 into the last equation, we get:
[tex]3(16)+1.5(8)=t[/tex]