#include <bits/stdc++.h>
#define INF 2147483647
#define LINF 9223372036854775807
#define NINF -2147483648
#define NLINF -9223372036854775808
#define M 1000000007
#define M1 998244353
#define A 26
#define K 31
#define P 2137
using namespace std;
using db=double;
using dbl=long double;
using ll=long long;
using pi=pair<int,int>;
using pl=pair<ll,ll>;
using vi=vector<int>;
using vl=vector<ll>;
using gr=vector<vector<int> >;
using grl=vector<vector<ll> >;
#define fp(x, a, b) for (int (x) = (a); (x) < (b); (x)++)
#define f(x, n) for (int (x) = 0; (x) < (n); (x)++)
#define fnp(x, a, b) for (int (x) = (b) - 1; (x) >= (a); (x)--)
#define fn(x, n) for (int (x) = (n - 1); (x) >= 0; (x)--)
#define sgn(x) (x) > 0 ? 1 : (x) == 0 ? 0 : -1
#define gcd(a, b) __gcd((a), (b))
#define lcm(a, b) (a) * (b) / gcd((a), (b))
#define x first
#define y second
#define mp make_pair
#define pb push_back
#define s(x) x.size()
#define all(x) x.begin(), x.end()
#define ans(x) cout<<(x)<<"\n"
#define yes cout<<"YES\n";
#define no cout<<"NO\n";
#define fl cout.flush()
#define debarr(x, n) f(i, (n)){cout<<(x)[i]<<" ";}cout<<"\n"
#define debgr(x, n) f(i, (n)){f(j, s((x)[i])){cout<<(x)[i][j]<<" ";}cout<<"\n";}
mt19937 rnd(chrono::high_resolution_clock::now().time_since_epoch().count());
void input();
void compute();
int main()
{
ios_base::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
int T = 1;
//cin >> T;
while(T--)
{
input();
compute();
}
return 0;
}
#define N 5001
string s1;
string s2;
string w;
int carry;
void input()
{
cin >> s1 >> s2;
}
void compute()
{
w = "";
carry = 0;
if(s(s1) < s(s2)) {
swap(s1, s2);
}
while(s(s1) != s(s2)) {
s2 = '0' + s2;
}
fn(i, s(s1)) {
int sum = s1[i] - '0' + s2[i] - '0' + carry;
carry = sum / 10;
sum %= 10;
w += sum + '0';
}
if(carry > 0) {
w += carry + '0';
}
reverse(all(w));
ans(w);
}