Final answer:
By setting up a system of equations based on the given information and solving for the variables, it is determined that each pizza costs $15 and each sandwich costs $8.
Step-by-step explanation:
To solve for the cost of each pizza and sandwich, we can set up a system of equations based on the given information:
- Two pizzas and four sandwiches cost $62. (Equation 1)
- Four pizzas and ten sandwiches cost $140. (Equation 2)
Let p represent the price of one pizza and s represent the price of one sandwich. We can express the given information as two linear equations:
- 2p + 4s = 62
- 4p + 10s = 140
Now, we can multiply equation 1 by 2 to help us eliminate one of the variables when we subtract one equation from the other:
- (2p + 4s) * 2 = 62 * 2
- 4p + 8s = 124 (Equation 3)
Subtracting equation 3 from equation 2 gives us:
- 4p + 10s - (4p + 8s) = 140 - 124
- 2s = 16
- s = 16 / 2
- s = 8
Since we now know the cost of one sandwich (s), we can substitute this back into equation 1 to find the cost of one pizza:
- 2p + 4(8) = 62
- 2p + 32 = 62
- 2p = 62 - 32
- 2p = 30
- p = 30 / 2
- p = 15
Therefore, each pizza costs $15, and each sandwich costs $8.