#include <bits/stdc++.h>
using namespace std;
const long long int inf = (long long int)1e18 + 19;
void cazz() {
  long long int n = 0, i, j;
  long long int s, t;
  cin >> s >> t;
  if (s == t && t == 0) {
    cout << 0;
    return;
  }
  vector<long long int> v1, v2, v;
  while (s > 0) {
    v1.push_back(s % 10);
    s /= 10;
  }
  while (t > 0) {
    v2.push_back(t % 10);
    t /= 10;
  }
  long long int l1 = v1.size(), l2 = v2.size(), l;
  if (l1 > l2) {
    l = l1 - l2;
    for (long long int i = 0; i < l; i++) {
      v2.push_back(0);
      for (j = v2.size() - 1; j > 0; j--) swap(v2[j], v2[j - 1]);
    }
  } else if (l1 < l2) {
    l = l2 - l1;
    for (long long int i = 0; i < l; i++) v1.push_back(0);
  }
  int n1, f = 0;
  j = l = v1.size();
  for (long long int i = 0; i < l; i++) {
    int sm = v1[i] + v2[j - 1] + n;
    if (sm > 9) {
      n1 = (sm % 10);
      sm /= 10;
      n = sm % 10;
    } else {
      n = 0;
      n1 = sm;
    }
    v.push_back(n1);
    j--;
  }
  f = 0;
  if (v[v.size() - 1] == 0) f = 1;
  if (n != 0) v.push_back(n);
  for (long long int i = v.size() - 1; i >= 0; i--) {
    if (v[i] != 0) f = 0;
    if (f) continue;
    cout << v[i];
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  cazz();
  return 0;
}
