#include <bits/stdc++.h>
using namespace std;
void solution(string s1, string s2);
void putData(string s1, string s2);
const int MAXSIZE = 10001;
int a[MAXSIZE] = {};
int b[MAXSIZE] = {};
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
string s1, s2;
cin >> s1 >> s2;
solution(s1, s2);
return 0;
}
void solution(string s1, string s2)
{
int maxSize, minSize, N;
if (s1.length() > s2.length())
{
putData(s1, s2);
minSize = s2.length();
maxSize = s1.length();
}
else
{
putData(s2, s1);
minSize = s1.length();
maxSize = s2.length();
}
for (int i = 0; i < minSize; i++)
{
a[i] += b[i];
if (10 <= a[i])
{
a[i] -= 10;
a[i + 1]++;
N = i + 1;
}
}
for (int i = minSize; i < maxSize; i++)
{
if (10 <= a[i])
{
a[i] -= 10;
a[i + 1]++;
N = i + 1;
}
}
N = max(N + 1, maxSize);
for (int i = N -1; 0 <=i; i--)
cout << a[i];
}
void putData(string s1, string s2)
{
for (int i = 0; i < s1.length(); i++)
{
a[i] = s1[s1.length() - 1 - i] - '0';
}
for (int i = 0; i < s2.length(); i++)
{
b[i] = s2[s2.length() - 1 - i] - '0';
}
}