Advertisement
Josif_tepe

Untitled

Mar 10th, 2021
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.27 KB | None | 0 0
  1. #include <iostream>
  2. #include <algorithm>
  3. using namespace std;
  4.  
  5. int max(int a, int b) {
  6.     if(a > b) {
  7.         return a;
  8.     }
  9.     else {
  10.         return b;
  11.     }
  12. }
  13. int main()
  14. {
  15.     int a, b;
  16.     cin >> a >> b;
  17.     cout << max(a, b) << endl;
  18.     return 0;
  19. }
  20.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement