Question: THE CODE SHOULD BE IN JAVA. Implement the extended Euclidean algorithm to find the greatest common divisor of any two positive integers a and b,

THE CODE SHOULD BE IN JAVA.
Implement the extended Euclidean algorithm to find the greatest common divisor of any two positive integers a and b, as well as values for s and t such that sx a +txb = gcd(a,b). It should also provide an accurate response if the user enters a zero. It should implement the pseudocode provided in the text. It should allow the user to enter two integers a and b. Your program should output the intermediate values of q, r, r1, r2, 5, 51, 52, t, t1, and t2 for each step. It should return the greatest common divisor and values fors and t. Challenge task: Provide error checking to confirm that the input is not negative. This is an individual assignment. Upload the following 1) a file of the code 2) screenshots of output for at least 4 pairs of inputs
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
