Divisibility, Euclid's algorithm and unique factorisation
Warm-upHumanUse Euclid's algorithm to compute .
Practice · Grades 9–12
Use Euclid's algorithm to compute .
Which pairs satisfy ? (Choose all that apply.)
For which of these numbers is it true that for all integers : if then or ? (Choose all that apply.)
Compute .
Which of these fractions have a terminating decimal expansion? (Choose all that apply.)
In the proof of Euclid's lemma we assume and , and then say . Why?
With a -litre jug, a -litre jug and a tap, what is the smallest positive amount of water you can measure exactly (by filling, emptying and pouring between the jugs)?
In the Hilbert numbers (numbers of the form ), which statement is true?
Which Lean statement correctly formalises Euclid's lemma for natural numbers?
Write extended_gcd(a, b) for natural numbers a, b (not both zero), returning a triple (g, x, y) with g == gcd(a, b) and a * x + b * y == g. Use the recursion: if b == 0 return (a, 1, 0); otherwise get (g, x, y) for (b, a % b) and back-substitute using a % b == a - (a // b) * b.