Two answers, one machine
This gcd and lcm calculator answers before you finish typing — Euclid's divisions scroll out beneath the screen, prime factorizations assemble beneath them, and every claim is cross-checked before it reaches your eyes. No equals button; the proof is live.
TWO INTEGERS MINIMUM · THIRD OPTIONAL · SPACES & COMMAS STRIPPED · EACH NUMBER ≤ 10¹²
How to use it
Sixty seconds from open to answer. The machine is deliberately plain — three boxes, three modes — but every panel underneath it is doing real mathematics, and nothing is hidden.
Pick your mode
GCD hunts the greatest common divisor, LCM the least common multiple, and BOTH returns the two side by side — with the identity gcd × lcm = a × b checked on screen.
Enter your integers
Two numbers are required; the third box is optional and folds the result to a triple. Thousand-commas and stray spaces are stripped as you type, and the arithmetic stays exact end to end.
Watch it solve live
There is no equals button. The screen re-solves on every keystroke, and the work panel beneath rewrites Euclid's algorithm line by line — every quotient, every remainder.
Read the rows
The big line is the answer. The rows beneath carry the prime factorization of each input, the shared primes behind the gcd, the highest powers behind the lcm, and a coprime verdict.
Trust, then verify
Nothing is asserted without a check: the lcm is recomputed through the formula a·b ÷ g as a second opinion, and BOTH mode multiplies out the identity in front of you.
Use the example chips
One tap loads a worked scenario — a textbook pair, a three-number fold, a coprime near-miss like 8 and 9, or a gear-style pair like 360 and 84.
Questions, answered
The nine questions every gcd–lcm hunt eventually arrives at — answered the way the tool works: exactly.