fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int a,b,c;
  5. scanf("%d %d %d",&a,&b,&c);
  6. if(a>b)
  7. {int tmp=a; a=b; b=tmp;};
  8. if(b>c)
  9. {int tmp=b; b=c; c=tmp;};
  10. if(a>b)
  11. {int tmp=a; a=b; b=tmp;};
  12. printf("%d %d %d ",a,b,c);
  13.  
  14. return 0;
  15. }
  16.  
Success #stdin #stdout 0s 5288KB
stdin
1 2 3 
stdout
1 2 3