#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int n, m;
  cin >> n >> m;
  long long int k = 0, l, j;
  long long int m1 = m;
  long long int count = 0;
  while (m1 != 0) {
    count++;
    m1 = m1 / 10;
  }
  l = pow(10, count - 1);
  while (m != 0) {
    j = m % 10;
    k = k + j * l;
    l = l / 10;
    m = m / 10;
  }
  cout << k + n;
}
