Advertisement
Farjana_akter

Untitled

Mar 30th, 2019
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. #include<stdio.h>
  2. int main()
  3. {
  4. double a, b, c, temp;
  5.  
  6. scanf("%lf %lf %lf", &a, &b, &c);
  7.  
  8. if (a < b)
  9.  
  10. {
  11.  
  12. temp = a;
  13.  
  14. a = b;
  15.  
  16. b = temp;
  17.  
  18. }
  19.  
  20. if (b < c)
  21.  
  22. {
  23.  
  24. temp = b;
  25.  
  26. b = c;
  27.  
  28. c = temp;
  29.  
  30. }
  31. if (a < b)
  32.  
  33. {
  34.  
  35. temp = a;
  36.  
  37. a = b;
  38.  
  39. b = temp;
  40.  
  41. }
  42.  
  43.  
  44. printf("%lf %lf %lf",a,b,c);
  45. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement