How to solve a system of equations by substitution
Solve one equation for one variable, put that expression into the other equation, and you're left with a single equation in one variable.
A worked example
Solve y = 2x − 1 and 3x + y = 9. The first equation already gives y, so replace y in the second: 3x + (2x − 1) = 9. Then 5x − 1 = 9, so 5x = 10 and x = 2. Back in the first equation, y = 2(2) − 1 = 3. The solution is (2, 3). Check in the second equation: 3(2) + 3 = 9.
The mistake people actually make
Put the substituted expression in brackets. Without them, 3x − (2x − 1) becomes 3x − 2x − 1, and the sign of the last term is wrong.