

If ‘a’, ‘b’, and ‘c’ are 5, 10, and 10 respectively, the initial integral solution will be 2 and 0 for ‘x’ and ‘y’ respectively.
The first line contains an integer 'T' which denotes the number of test cases or queries to be run.
The first line of each test case contains three space-separated integers ‘a’, ‘b’, and ‘c’.
For each case, you need to return an array containing the value of both x and y if a finite solution exists. In case, there exists no finite solution, you can return -1 for both x and y.
The output of each test case will be printed in a separate line.
You do not need to input or print anything, and it has already been taken care of. Just implement the given function.
1 <= T <= 5
1 <= a <= 100000
1 <= b <= 100000
1 <= c <= 100000
Time Limit: 1 sec
Here, we can use the extended euclidean algorithm which helps us to find the solution of a linear equation using the greatest common divisor(gcd) of the coefficients of x and y. Using this gcd, if this gcd is a divisor of ‘c’, then we can find the solution for the equation ‘ax + by = c’.
Pair Product Div by K
Pair Product Div by K
Merge Two Sorted Arrays Without Extra Space
Merge Two Sorted Arrays Without Extra Space
Co-Prime
First Digit One
Special Digit Numbers