Question 48121
You are working with two different variables, x is one variable and y is the other variable.  Since you have two variables, use the following formula:
Ax + By = C
.
.
A = rate, cost or percent of A = $7
x = the amount or number of A = x
B = rate, cost or percent of B = $2
y = the amount or number of B = y
C = the total amount = $111
.
Expensive ones = $7x [We do not know how many expensive items are available]
Worthless ones = $2y [We do not know how many worthless items are available]
Total amount spent = C = $111
.
Ax + By = C [Formula for linear equations]
7x + 2y = 111 [Plug-in the values]
.
But, there is one more piece of information -- "...and bought three more expensive ones than worthless ones".  
This translate into:
Number of expensive ones (x) = Number of Worthless ones (y) + 3 more
x = y + 3 [Substitute this (y + 3) in the equation]
.
7(y+3) + 2y = 111 [Simplify]
7y + 21 + 2y = 111  [Solve for y]
9y + 21 = 111
9y + 21 - 21 = 111 - 21
9y = 90
9y/9 = 90/9
y = 10
.
Plug (y=10) back into the original equation and solve for x]
7x + 2y = 111
7x + 2(10) = 111
7x + 20 = 111
7x + 20 - 20 = 11 - 20
7x = 91
7x/7 = 91/7
x = 13
.
Check by plugging all of the values back into the original equation.
7x + 2y = 111
7(13) + 2(10) = 111
7(13) + 2(10) = 111
111 = 111 [Checks out]