#include <iostream>
#include <string>
using namespace std;
int main(){
string s1,s2;
char p1[1000] = {0},p2[1000] = {0};
cin >> s1 >> s2;
int cnt1=0, cnt2 =0;
for(int i=s1.length()-1; i >=0; i--){
p1[cnt1++] = s1[i];
p2[cnt2++] = s2[i];
}
int T1 = stoi(p1);
int T2 = stoi(p2);
if(T1 > T2) cout <<T1;
else cout << T2;
return 0;
}
'백준알고리즘' 카테고리의 다른 글
백준 1712 C++ (0) | 2021.07.02 |
---|---|
백준 5622 C++ (0) | 2021.07.02 |
백준 1152 C++ (0) | 2021.07.01 |
백준 1157 C++ (0) | 2021.07.01 |
백준 2675 C++ (0) | 2021.07.01 |