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