#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, c, re, rev = 0;
  cin >> c >> a;
  while (a != 0) {
    re = a % 10;
    rev = rev * 10 + re;
    a /= 10;
  }
  cout << c + rev;
  return 0;
}
