Construct a trace table to trace the action of the algorithm below for the input variables given. a := 5,862, b := 1,240, r := 1,240 while (b + 0) r:=a mod b a:=b b:=r end while gcd :=a iteration 1 3 4 5 6 a 5,862 1,240 r 1,240 gcd gcd(5,862, 1,240) =

Algebra & Trigonometry with Analytic Geometry
13th Edition
ISBN:9781133382119
Author:Swokowski
Publisher:Swokowski
Chapter10: Sequences, Series, And Probability
Section10.2: Arithmetic Sequences
Problem 52E
icon
Related questions
Question
Construct a trace table to trace the action of the algorithm below for the input variables given.
a := 5,862, b := 1,240, r:= 1,240
while (b ± 0)
r:=a mod b
a:=b
b:=r
end while
gcd :=a
iteration
1
2
3
4
6
a
5,862
1,240
1,240
gcd
gcd(5,862, 1,240)
Transcribed Image Text:Construct a trace table to trace the action of the algorithm below for the input variables given. a := 5,862, b := 1,240, r:= 1,240 while (b ± 0) r:=a mod b a:=b b:=r end while gcd :=a iteration 1 2 3 4 6 a 5,862 1,240 1,240 gcd gcd(5,862, 1,240)
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 1 images

Blurred answer