Lucian_Adrian

Untitled

Aug 22nd, 2021
35
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. #include <iostream>
  2. #include <fstream>
  3. using namespace std;
  4. int main()
  5. {
  6. ifstream istr;
  7. ofstream ostr;
  8.  
  9. istr.open("maxim3.in");
  10. ostr.open("maxim3.out");
  11.  
  12. int a,b,c;
  13. istr >> a >> b >> c;
  14. if (a>b && a>c)
  15. ostr << a;
  16. else if (b>a && b>c)
  17. ostr << b;
  18. else
  19. ostr<< c;
  20. istr.close();
  21. ostr.close();
  22. return 0;
  23. }
Advertisement
Add Comment
Please, Sign In to add comment