mhdew

lkjh

Oct 10th, 2017
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. #include<stdio.h>
  2.  
  3. int main()
  4. {
  5. int a,b,c;
  6.  
  7. scanf("%d%d%d", &a,&b,&c);
  8.  
  9. if(a>b&&b>c)
  10. printf("%d is 2nd largest\n", b);
  11. if(c>b&&b>a)
  12. printf("%d is 2nd largest\n", b);
  13. if(b>a&&a>c)
  14. printf("%d is 2nd largest\n", a);
  15. if(c>a&&a>b)
  16. printf("%d is 2nd largest\n", a);
  17. else
  18. printf("%d is 2nd largest\n", c);
  19.  
  20. return 0;
  21. }
Advertisement
Add Comment
Please, Sign In to add comment