BETA
This is a school problem. Successful submissions of this are not counted in user ratings.

Submissions : 1641 Accuracy :

19.13

Roots of Quadratic Equation
     

Given a quadratic equation in the form ax2 + bx + c, find floor of roots of it.  For example floor of 5.6 is 5.

Input:  First line contains an integer, the number of test cases 'T'. Each test case should contain three positive numbers a,b and c.

Output:  If roots of equations exits, then print the two roots separated by space (Higher valued root should be printed before lower valued). Else if a = 0, then print "Invalid" as equation is not quadratic.  If roots are imaginary, then print "Imaginary"

Constraints:
1<=T<=50
1<=a<=1000
1<=b<=1000
1<=c<=1000


Example:
Input:
3
1 -2 1
1 -7 12
1 4 8

Output:
1 1
4 3
Imaginary

**For More Examples Use Expected Output**


Set Default Code

					   
Result:
It is recommended to test your code before clicking 'Submit' button!



                   



Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.