Given four integers a,b,m,n . Find whether pow(a,b) is greater than pow(m,n) or not. Where pow(x,y) denotes x raised to the power y.
First line of input contains of an integer 'T 'denoting number of test cases .Only line of each testcase contains four integers a,b,m and n .
For each case in a new line print 1 if pow(a,b) is greater , print 0 if pow(m,n) is greater else print -1 if both are equal.
2 2 3 2
1 23 1 34
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.