#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, m, p;
  string s, s1;
  cin >> n >> s;
  p = 1;
  m = 0;
  for (int i = 0; i < s.size(); i++) {
    m += p * (s[i] - '0');
    p *= 10;
  }
  cout << m + n;
  return 0;
}
