Welcome back to Solving Systems by Substitution! You are now on lesson two of five, so you are making great progress through this course. In the previous lesson, we learned the full substitution process when one equation already had a variable isolated for us. That was a perfect starting point, but real-world systems rarely arrive so neatly packaged. Today, we will learn how to rearrange an equation first so that we create an isolated variable, and then carry out the same substitution steps you already know.
When No Variable Starts Isolated
Spotting the Right Variable to Isolate
Join the 1M+ learners on CodeSignal
Be a part of our community of 1M+ users who develop and demonstrate their skills on CodeSignal
Substitution works by replacing one variable with an equivalent expression from the other equation. In the previous lesson, that replacement was straightforward because we had equations like y=3x−2, where y was already alone on one side.
Now consider a system like this:
x+2y=73x−y=7
Neither equation hands us a variable on a silver platter. Does that mean substitution is off the table? Not at all — we just need one extra preliminary step: pick a variable in one equation and move everything else to the other side. Once we do that, we are right back to the process we already practiced.
Before we start rearranging, it pays to scan both equations for the easiest variable to isolate. The golden clue is the coefficient — the number multiplying the variable. If a variable has a coefficient of 1 or −1, isolating it requires only adding or subtracting terms, with no division needed.
Look at our system again:
Equation
Variable
Coefficient
x+2y=7
x
1
x+2y=7
y
2
3x−y=7
x
3
3x−y=7
y
−1
Two strong candidates jump out: x in the first equation (coefficient 1) and y in the second equation (coefficient −1). Either choice avoids division entirely. In contrast, isolating y from the first equation would mean dividing by 2, and isolating x from the second would mean dividing by 3 — both of which introduce fractions and extra room for error.
Keep this principle in mind: the choice of which variable to isolate affects convenience, not correctness. Every valid isolation leads to the same final answer. For this lesson, we will focus on coefficient-1 and coefficient-(−1) variables to keep the rearranging step clean.
Rearranging a Coefficient-One Variable
Walking Through a Full Example
Handling a Coefficient of Negative One
A Real-World Application
Common Pitfalls to Watch For
Conclusion and Next Steps
In this lesson, you extended the substitution method to systems where no variable starts isolated. The new first step is to scan both equations for a variable with a coefficient of 1 or −1, isolate it through simple addition or subtraction, and then follow the same substitute, solve, back-substitute, and verify process you learned before. This small addition opens up a much wider range of systems you can handle.
Now it is time to sharpen these skills hands-on. The upcoming practice exercises will guide you from spotting the best variable to isolate, all the way through solving and verifying complete systems — including a real-world grocery scenario — on your own. Let's jump in!
Let's isolate x from the first equation, x+2y=7. Since x already has a coefficient of 1, all we do is subtract 2y from both sides:
x=7−2y
That is the entire rearrangement — no division, no fractions. We now have x expressed in terms of y, which is exactly the kind of equation we worked with in the previous lesson. From here, the substitution process is identical.
Let's solve the system we introduced earlier from start to finish:
x+2y=73x−y=7
Step 1 — Rearrange. Isolate x in the first equation:
x=7−2y
Step 2 — Substitute. Replace x in the second equation with (7−2y). Remember your parentheses:
3(7−2y)−y=7
Step 3 — Solve. Distribute and combine like terms:
21−6y−y=721−7y=7−7y=−14y=2
Step 4 — Back-substitute. Plug y=2 into the rearranged equation to find x:
x=7−2(2)=7−4=3
Our solution is the ordered pair (3,2).
Verify in both original equations:
Equation 1:3+2(2)=3+4=7✓
Equation 2:3(3)−2=9−2=7✓
Both equations check out. Notice that the only new work compared to the previous lesson was Step 1 — rearranging. Once the variable was isolated, the rest of the process was business as usual.
When a variable has a coefficient of −1, the isolation step is almost as simple, but you need to be a little more careful with signs. Consider this system:
4x+y=11x−y=4
Scanning for candidates, y in the first equation has coefficient 1 and y in the second has coefficient −1. Both are great choices. Let's isolate y in the first equation to highlight an important detail about signs during substitution:
y=11−4x
Now substitute into the second equation:
x−(11−4x)=4
Here is where parentheses really earn their keep. The minus sign in front of the parentheses flips every sign inside:
x−11+4x=45x−11=45x=15x=3
Back-substitute:
y=11−4(3)=11−12=−1
Our solution is (3,−1).
Verify:
Equation 1:4(3)+(−1)=12−1=11✓
Equation 2:3−(−1)=3+1=4✓
What about isolating the −1 coefficient variable directly? From x−y=4, you would subtract x from both sides to get −y=4−x, then multiply by −1 to obtain y=x−4. That approach works perfectly and leads to the same answer. Whichever route you choose, the key takeaway is the same: when you substitute into a spot where a subtraction sign sits in front, wrap the expression in parentheses and distribute the negative sign to keep everything accurate.
To see this technique in a practical setting, imagine you and a friend buy snacks at a stadium. You buy one hot dog and two sodas for $11, while your friend buys three hot dogs and one soda for $13. If h is the price of a hot dog and s is the price of a soda:
h+2s=113h+s=13
Rearrange. The variable h in the first equation has a coefficient of 1, so isolating it is one step:
h=11−2s
Substitute into the second equation:
3(11−2s)+s=13
Solve:
33−6s+s=1333−5s=13−5s=−20s=4
Back-substitute:
h=11−2(4)=11−8=3
A hot dog costs $3 and a soda costs $4.
Verify:
Equation 1:3+2(4)=3+8=11✓
Equation 2:3(3)+4=9+4=13✓
The process is exactly the same whether the variables represent abstract quantities or real-world prices. Spotting that h had a coefficient of 1 made the rearranging step quick and clean.
A few mistakes tend to crop up when rearranging is involved:
Forgetting to flip signs when isolating a −1 coefficient variable. If you reach −y=3−2x, you must multiply both sides by −1 to get y=2x−3. Leaving the negative on y will throw off every step that follows.
Dropping parentheses during substitution. After rearranging, your expression often has multiple terms (like 11−2s). Parentheses protect those terms when they land inside the other equation, especially when a subtraction sign sits in front.
Substituting into the same equation you rearranged. Always substitute into the other equation. Putting the expression back where it came from will only produce an identity — a true but useless statement.