Code:
#include <stdio.h>
int main()
{
int a,b;
scanf("%d %d",&a,&b);
printf("%d %d",(a>b)? a,b:b,a);
return 0;
}

My objective was not to use if,else
Sample 1:
input output
1    2 

2 1
When the first integer is smaller the program works fine
Sample 2;
input output
2    1

1 2
When the first integer is greater than the second ,the output is wrong (it doesn't print in descending order)
From what I've understood ,I think that the Program only prints the false condition.
Please help and fix this program. Thanks