Let
be the cost, respectively, of a notebook and a pen. If you buy 2 notebooks and 3 pens (which we know is a cost of $14.50), you spend

Similarly, if you buy 1 notebook and 2 pens (which we know is a cost of $7.50), you spend

These two equations form the following system:

Multiply the second equation by 2:

Subtract the first equation from the second:

So, a pen costs 0.5 dollars. Plug this equation in the second equation:
