Advertisement
Guest User

Untitled

a guest
Sep 19th, 2019
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main() {
  6.  
  7. float a,b,c;
  8. int t;
  9. cin>>a>>b>>c;
  10. if ((a>0) && (b>0) &&(c>0))
  11. {
  12. if ((a+b>c) && (b+c>a) && (c+a>b))
  13. if (a==b)
  14. if (b==c)
  15. t=3;
  16. else
  17. t=2;
  18. else
  19. if (a==c)
  20. t=2;
  21. else
  22. if (b==c)
  23. t=2;
  24. else
  25. t=1;
  26. }
  27. else
  28. t=0;
  29. cout<<t;
  30. return 0;
  31. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement