If a person bought 8 items and each item was priced at $4, that means the total amount spent was $32.

The person received 8 dollars in change. This means that the person payed 8 dollars more than what they spent. Well, we just found out how much they spent, so we can find out how much money the person gave the vendor.
Let p = amount of money paid by the person.


The person gave the vendor $40.