How to solve for a missing side: finding a, b, or c step by step
Every Pythagorean theorem problem is one of exactly three jobs: find the hypotenuse, or find one of the two legs. The formula never changes — a² + b² = c² — but the algebra does, and mixing up the versions is where most wrong answers are born: students rarely fail on the square roots, they fail on adding when they should subtract.
Every Pythagorean theorem problem is one of exactly three jobs: find the hypotenuse, or find one of the two legs. The formula never changes — a2 + b2 = c2 — but the algebra does, and mixing up the versions is where most wrong answers are born. I have marked enough of these to know the pattern: students rarely fail on the square roots; they fail on adding when they should subtract. So this guide treats the three jobs separately, each with its own rearranged formula, fully worked examples with every line of arithmetic shown, and the sanity checks that catch the classic error before it costs you.
- Name the sides correctly first: c is always the hypotenuse, opposite the right angle — most wrong answers are born before any arithmetic.
- Finding a leg means subtract, never add: a² = c² − b². Adding when you should subtract is the mistake I see more than all others combined.
- Before solving, I check the triangle is right-angled at all — the theorem only speaks for right triangles.
- First, name the sides correctly
- Job 1 — finding c: the hypotenuse
- Job 2 — finding a leg: subtract, never add
- Job 3 — how to find b in the Pythagorean theorem
- The mistake box: the error I see more than all others combined
- Before solving: check the triangle is right-angled at all
- Two real problems, start to finish
- Frequently asked questions
First, name the sides correctly
Before any formula, label the triangle. The side called c is always the hypotenuse: the side opposite the right angle, and always the longest of the three. The other two sides, a and b, are the legs — and here is the freedom that confuses people: it does not matter which leg you call a and which you call b. The formula is symmetric in the legs, so swapping their names changes nothing. What you may never do is let c be anything other than the hypotenuse. If a problem gives you a triangle with sides 5 and 13 where 13 is opposite the right angle, then c = 13 and one of your legs is 5 — even if the diagram labels the 13 side “a”. Trust the right angle, not the lettering. Every worked example below starts from that one habit.
Job 1 — finding c: the hypotenuse
When both legs are known, use the formula as written and solve for c:
Worked example 1. Legs of 8 and 15. Square them: 82 = 64 and 152 = 225. Add: 64 + 225 = 289. Root: √289 = 17. The hypotenuse is 17 — you may recognise 8-15-17 from the triples list; textbook problems are full of it.
Worked example 2. Legs of 9 and 12. Squares: 81 and 144. Sum: 225. Root: √225 = 15. (That is 3-4-5 scaled by 3, and recognising the family gets you the answer before the arithmetic does.)
Worked example 3 — the honest kind. Legs of 4 and 7. Squares: 16 and 49. Sum: 65. Root: √65 ≈ 8.06. Most real triangles end like this, in a decimal, and that is fine: report the root exactly (√65) for exact work, or round sensibly — 8.06 to two decimals, 8.1 to one. What you should never do is round mid-problem and then feed the rounded value into a later step; keep the full value until the final line.
It is no accident that “pythagorean theorem calculator find c” is the most-typed version of this search: the hypotenuse is the side people need in the real world — diagonals, distances, ladder lengths — and it is also the friendliest job, because the formula needs no rearranging. The other two jobs are where the theorem earns its reputation.
Job 2 — finding a leg: subtract, never add
When the hypotenuse and one leg are known, the formula turns inside out. You are peeling one square away from the hypotenuse’s square:
Worked example 1. Hypotenuse 25, known leg 24; find the other leg. Squares: 252 = 625 and 242 = 576. Subtract: 625 − 576 = 49. Root: √49 = 7. The triangle is 7-24-25.
Worked example 2. Hypotenuse 13, known leg 5. Squares: 169 and 25. Subtract: 144. Root: √144 = 12 — the 5-12-13 triple again.
Worked example 3 — decimal answer. Hypotenuse 17, known leg 9. Squares: 289 and 81. Subtract: 208. Root: √208 ≈ 14.42. Notice that the missing leg (14.42) is shorter than the hypotenuse (17) — hold that thought, because it is your built-in error detector: a leg can never be longer than the hypotenuse. If your subtraction version ever produces a leg longer than c, the arithmetic is wrong, full stop. Searches like “pythagorean theorem calculator find a” spike every exam season precisely because this job punishes one specific slip, which the next section isolates.
Job 3 — how to find b in the Pythagorean theorem
Finding b is the same job as finding a — the legs are interchangeable — but it deserves its own walk-through, because textbook diagrams so often label the horizontal leg b and the hypotenuse c, leaving b as the unknown. The rearranged formula mirrors the a version exactly:
Worked example 1. Hypotenuse 26, leg a = 10; find b. Squares: 262 = 676 and 102 = 100. Subtract: 676 − 100 = 576. Root: √576 = 24. The triangle is 10-24-26 — the 5-12-13 family doubled.
Worked example 2. Hypotenuse 10, leg a = 6; find b. Squares: 100 and 36. Subtract: 64. Root: √64 = 8 — the 6-8-10 triangle, 3-4-5 doubled.
So the routine for how to find b in pythagorean theorem questions is identical to the routine for a, and the search phrase “pythagorean theorem find b” leads to the same three lines every time: square c, subtract the known square, root the result. If you remember nothing else, remember the order — the hypotenuse is squared first and the known leg is taken away from it. Reversing the subtraction (leg squared minus hypotenuse squared) gives a negative number under the root, which is the theorem’s way of telling you the steps are backwards.
The mistake box: the error I see more than all others combined
Three more checks I run on every missing-side answer, and I recommend them until they are reflexes:
- The longest-side check. c must be the largest number in the finished triangle. Any result that breaks this is wrong, however confident the arithmetic felt.
- The plug-back check. Square your answer and the two given sides and confirm a2 + b2 = c2 holds exactly (or to rounding, for decimals). Fifteen seconds, total certainty.
- The size sense check. A leg close in length to the hypotenuse means the other leg is short (24 with hypotenuse 25 leaves just 7); a leg near the hypotenuse’s half means the other leg is long. If the picture in your head disagrees with the number on the page, redo the number.
Before solving: check the triangle is right-angled at all
The theorem — and this whole page — applies only to right triangles, and the converse of the theorem gives you a test for that. Take the three sides, square the two shorter ones, and compare their sum with the square of the longest:
| Sides | a² + b² | c² | Verdict |
|---|---|---|---|
| 7, 24, 25 | 49 + 576 = 625 | 625 | Right triangle — equal |
| 6, 8, 10 | 36 + 64 = 100 | 100 | Right triangle — equal |
| 4, 5, 6 | 16 + 25 = 41 | 36 | Acute — a² + b² is larger |
| 5, 6, 9 | 25 + 36 = 61 | 81 | Obtuse — a² + b² is smaller |
The converse test on four triangles. Equal means the angle opposite the longest side is exactly 90°.
This is more than an exam trick. It is how builders verify a corner is square (the 3-4-5 check is the converse in work boots), and it is the first thing to run when a problem hands you all three sides and asks about the angle: the numbers tell you which kind of triangle you are holding before you solve anything.
Two real problems, start to finish
The throw to second base. A baseball diamond is a square with 90 ft sides, so the catcher’s throw from home plate to second base is a hypotenuse with both legs equal to 90. c = √(902 + 902) = √(8,100 + 8,100) = √16,200 ≈ 127.28 ft — 127 ft and about 3.35 in. Notice this is the missing-side machinery running Job 1 with a = b, and notice the answer is not a whole number: the diamond is a square, and a square’s diagonal is side × √2, which never lands even.
The map distance. Two points on a grid, (1, 2) and (4, 6): the horizontal gap is 4 − 1 = 3 and the vertical gap is 6 − 2 = 4, so the straight-line distance is √(9 + 16) = √25 = 5. That is the distance formula from coordinate geometry, and it is nothing but Job 1 wearing a grid — the theorem again, which is why I treat “distance between two points” and “hypotenuse” as the same skill.
Solve for any side, with the working shown
Enter the two sides you know — any two — and get the missing one instantly, hypotenuse or leg, with the rearranged formula applied for you.
Open the Pythagorean Theorem CalculatorFrequently asked questions
How do I find c in the Pythagorean theorem?
Square both legs, add the squares, and take the square root of the total. With legs of 8 and 15: 64 + 225 = 289, and the square root of 289 is 17, so c is 17. Finding c is the one job that uses the formula exactly as it is written, with no rearranging.
How do I find a missing leg when I know the hypotenuse?
Square the hypotenuse, subtract the square of the leg you know, and take the square root of the difference. With a hypotenuse of 25 and a known leg of 24: 625 minus 576 is 49, and the square root of 49 is 7. The subtraction is the step people miss — adding instead produces a leg longer than the hypotenuse, which is impossible.
How do I find b in the Pythagorean theorem?
The same way you find any leg: b equals the square root of c squared minus a squared. With a hypotenuse of 26 and leg a of 10: 676 minus 100 is 576, and the square root of 576 is 24, so b is 24. The legs a and b are interchangeable in the formula, so the method never depends on which leg the problem asks for.
What if the missing side is not a whole number?
Then the answer is a decimal or a square root, and both are complete answers. Legs of 4 and 7 give a hypotenuse of the square root of 65, about 8.06. Whole-number answers only occur for Pythagorean triples like 3-4-5 and 8-15-17; most real measurements are not triples, so a decimal is the normal, expected result.
Can I use the Pythagorean theorem on a triangle with no right angle?
No — the theorem holds only for right triangles. If you know all three sides of another triangle, the converse test tells you which kind it is: if the squares of the two shorter sides add to more than the square of the longest side the triangle is acute, and if they add to less it is obtuse. Only exact equality means a right angle, and only then do the formulas on this page apply.
Sources: formulas and the converse test follow the standard statements in Euclid’s Elements, Book I, Propositions 47 and 48; every worked example in this article was recomputed and plug-back verified in Python before publication.
- 1Pythagorean triples: the complete list and how they work
Most right triangles end in a decimal: legs of 4 and 7 give a hypotenuse of about 8.06, and you round it and…
- 2Finding the hypotenuse in feet and inches: diagonal math for DIY and construction
Search for a hypotenuse calculator in feet and inches and most results hand you back a decimal — 14.1421…
