#include <bits/stdc++.h>
using namespace std;
int atoi(string s) {
  int sol = 0, st = 1;
  for (int i = 0; i < int(s.size()); i++) {
    sol += (s[i] - 48) * st;
    st *= 10;
  }
  return sol;
}
int main() {
  string a, b;
  cin >> a >> b;
  reverse(a.begin(), a.end());
  cout << atoi(a) + atoi(b) << endl;
}
