You can do it using the following logic:
Let us assume the numbers to be x and y.
printf("x is greater");
printf("y is greater");
If you divide a smaller number by a greater number the result will be "zero".
case 1: x<y
(x/y) results "0", in turn makes the condition if(o) => if(false) and so the else part is executed.
(x/y) results some positive value, in turn makes the condition to if(true) and so if part is executed.