3. (3 points) The Euclidean Algorithm is used to find the Greatest Common Divisor (GCD) of two positive numbers; i.e., GCD(10, 15) = 5, as 10 = 2 \times 5 and 15 = 3 \times 5. Below are the steps of the algorithm:
(i) We put the larger number into R1 and the other number into R2.
(ii) Keep subtracting R2 from R1, until R1 contains a smaller value than R2 does.
(iii) From Step (ii), if R1 contains a positive number, we exchange values in R1 and R2, and repeat Step (ii).
(iv) From Step (ii), if R1 contains a zero, we stop the program. What's in R2 is now the GCD.
Write an LC-3 assembly language program that implements the Euclidean Algorithm.
[Hint: Might have additional steps in between; utilize CC for comparisons.]