<image>

Input

The input contains two integers row, col (0 ≤ row, col ≤ 63), separated by a single space.

Output

Output "IN" or "OUT".

Examples

Input


0 0


Output


OUT


Input


27 0


Output


IN


Input


0 27


Output


OUT


Input


27 27


Output


IN
#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
#pragma GCC optimization("unroll-loops")
using namespace std;
template <class T>
inline T sqr(T x) {
  return x * x;
}
template <class T>
inline T parse(const string &s) {
  T x;
  stringstream ss(s);
  ss >> x;
  return x;
}
const double EPS = 1e-12;
const int INF = 1000 * 1000 * 1000;
const long long LINF = INF * 1ll * INF;
const double DINF = 1e200;
const double PI = 3.1415926535897932384626433832795l;
int gcd(int a, int b) { return a ? gcd(b % a, a) : b; }
long long gcd(long long a, long long b) { return a ? gcd(b % a, a) : b; }
long long gcdex(long long a, long long b, long long &x, long long &y) {
  if (!a) {
    x = 0, y = 1;
    return b;
  }
  long long k = b / a;
  long long g = gcdex(b - k * a, a, y, x);
  x -= k * y;
  return g;
}
long long inv(long long a, long long m) {
  assert(m > 1);
  long long x, y, g;
  g = gcdex(a, m, x, y);
  return (x % (m / g) + m / g) % m / g;
}
long long crt(long long a1, long long m1, long long a2, long long m2) {
  long long a = (a2 - a1 % m2 + m2) % m2;
  long long x, y, g;
  g = gcdex(m1, m2, x, y);
  if (a % g) return -1;
  long long m = m1 / g * m2;
  assert(x + m2 >= 0);
  x = a / g * (x + m2) % m2;
  long long r = (a1 + x * m1) % m;
  assert(r % m1 == a1 && r % m2 == a2);
  return r;
}
long long powmod(long long a, long long p, long long m) {
  assert(p >= 0);
  long long r = 1;
  while (p) {
    if (p & 1) r = r * a % m;
    p >>= 1;
    a = a * a % m;
  }
  return r;
}
bool isprime(long long a) {
  if (a <= 1) return false;
  for (long long i = 2; i * i <= a; ++i) {
    if (a % i == 0) return false;
  }
  return true;
}
long long sqrtup(long long a) {
  if (!a) return 0;
  long long x = max(0ll, (long long)sqrt((double)a));
  while (x * x >= a) --x;
  while ((x + 1) * (x + 1) < a) ++x;
  return x + 1;
}
long long isqrt(long long a) {
  if (a <= 0) {
    assert(!a);
    return 0;
  }
  long long x = (long long)sqrt((double)a);
  while (sqr(x + 1) <= a) ++x;
  while (x * x > a) --x;
  return x;
}
long long sgn(long long x) { return x < 0 ? -1 : x > 0 ? 1 : 0; }
double randf() {
  double m = RAND_MAX + 1.;
  return (((rand() + .5) / m + rand()) / m + rand()) / m;
}
template <class T>
ostream &operator<<(ostream &s, const vector<T> &v);
template <class A, class B>
ostream &operator<<(ostream &s, const pair<A, B> &p);
template <class K, class V>
ostream &operator<<(ostream &s, const map<K, V> &m);
template <class T>
ostream &operator<<(ostream &s, const set<T> &m);
template <class T, size_t N>
ostream &operator<<(ostream &s, const array<T, N> &a);
template <class... T>
ostream &operator<<(ostream &s, const tuple<T...> &t);
template <class T>
ostream &operator<<(ostream &s, const vector<T> &v) {
  s << '[';
  for (int i = 0; i < (((int)(v).size())); ++i) {
    if (i) s << ',';
    s << v[i];
  }
  s << ']';
  return s;
}
template <class A, class B>
ostream &operator<<(ostream &s, const pair<A, B> &p) {
  s << "(" << p.first << "," << p.second << ")";
  return s;
}
template <class K, class V>
ostream &operator<<(ostream &s, const map<K, V> &m) {
  s << "{";
  bool f = false;
  for (const auto &it : m) {
    if (f) s << ",";
    f = true;
    s << it.first << ": " << it.second;
  }
  s << "}";
  return s;
}
template <class T>
ostream &operator<<(ostream &s, const set<T> &m) {
  s << "{";
  bool f = false;
  for (const auto &it : m) {
    if (f) s << ",";
    f = true;
    s << it;
  }
  s << "}";
  return s;
}
template <class T>
ostream &operator<<(ostream &s, const multiset<T> &m) {
  s << "{";
  bool f = false;
  for (const auto &it : m) {
    if (f) s << ",";
    f = true;
    s << it;
  }
  s << "}";
  return s;
}
template <class T, class V, class C>
ostream &operator<<(ostream &s, const priority_queue<T, V, C> &q) {
  auto a = q;
  s << "{";
  bool f = false;
  while (!a.empty()) {
    if (f) s << ",";
    f = true;
    s << a.top();
    a.pop();
  }
  return s << "}";
}
template <class T, size_t N>
ostream &operator<<(ostream &s, const array<T, N> &a) {
  s << '[';
  for (int i = 0; i < (((int)(a).size())); ++i) {
    if (i) s << ',';
    s << a[i];
  }
  s << ']';
  return s;
}
template <class T>
ostream &operator<<(ostream &s, const deque<T> &a) {
  s << '[';
  for (int i = 0; i < (((int)(a).size())); ++i) {
    if (i) s << ',';
    s << a[i];
  }
  s << ']';
  return s;
}
template <size_t n, class... T>
struct put1 {
  static ostream &put(ostream &s, const tuple<T...> &t) {
    s << get<sizeof...(T) - n>(t);
    if (n > 1) s << ',';
    return put1<n - 1, T...>::put(s, t);
  }
};
template <class... T>
struct put1<0, T...> {
  static ostream &put(ostream &s, const tuple<T...> &t) { return s; }
};
template <class... T>
ostream &operator<<(ostream &s, const tuple<T...> &t) {
  s << "(";
  put1<sizeof...(T), T...>::put(s, t);
  s << ")";
  return s;
}
ostream &put3(ostream &s, const char *, bool) { return s; }
template <class U, class... T>
ostream &put3(ostream &s, const char *f, bool fs, U &&u, T &&...t) {
  while (*f == ' ') ++f;
  if (!fs) s << ", ";
  auto nf = f;
  int d = 0;
  while (*nf && (*nf != ',' || d)) {
    if (*nf == '(')
      ++d;
    else if (*nf == ')')
      --d;
    ++nf;
  }
  auto nf2 = nf;
  while (nf2 > f && *(nf2 - 1) == ' ') --nf;
  fs = *f == '"';
  if (!fs) {
    s.write(f, nf2 - f);
    s << "=";
  };
  s << u;
  if (fs) s << ' ';
  if (*nf) ++nf;
  return put3(s, nf, fs, forward<T>(t)...);
}
int main(int argc, char **argv) {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.precision(20);
  srand(35964);
  const char *a =
      "000000000000000000000000001010111111010000000000000000000000000000000000"
      "000000000000001011101010100101111100000000000000000000000000000000000000"
      "000011101000100011010000100100000000000000000000000000000000000001111010"
      "101111100001111010111010000000000000000000000000000000001100000010100000"
      "111100001010101100000000000000000000000000000010011011111011101110100101"
      "100010010100000000000000000000000000011100100100000010100011110011011011"
      "011000000000000000000000000111111011011011101110111000011001001000111000"
      "000000000000000000111111111111000010000010001011001101101001110000000000"
      "000000000111111111111111111110111111100111100111111111100000000000000000"
      "111111111111111111111111111111111111111111111111000000000000000111111111"
      "111111111111111111111111111111111111111110000000000000011111111111111111"
      "111111111111111111111111111111111000000000000011111111111111111111111111"
      "111111111111111111111111110000000000011111111111111111111111111111111111"
      "111111111111111111100000000001111111111111111111111111111111111111111111"
      "111111111110000000001111111111111111111111111111111111111111111111111111"
      "111100000001111111111111111111111111111111111111111111111111111111111000"
      "000001111111111111111111111111111111111111111111111111111111100000000001"
      "111111111110001001111111111111100010101111111111111000000011000001111111"
      "110010001111111111111110100000001111111100000000001111000001111100011010"
      "001111111111111110110110010110000000110001111111000001000111001110011111"
      "111111010010001100000000011111100111111111000001001001101100011111111101"
      "101111100100001111111110011111111111101101110000011100111111100010010000"
      "111011111111111001111111110000010001110111000111111110101111101000100101"
      "111111101111111111110111010010010001001111110010010000110111000111111111"
      "111111111110001001011011101110111101011101111001110001011111111111111111"
      "111011111101111000010010100001010010111100011101111111111111111111100000"
      "100100111011100010101101101001000100100111111111111111111111011011110110"
      "111000101110000011110101111110111111111111111111111000111001001000111010"
      "011101111001011100010001111111111111111111111000001101110110111011000001"
      "001101100100010111111111111111111111110110100001010000101001010110100011"
      "011011111111111111111111111100001111010101010111101101001011100111000111"
      "111111111111111111111010010001110001111000100110000100110001111111111111"
      "111111111111111100011100010110110110110010111010010011111111111111111111"
      "111111111100010111111000001111111000100011111111111111110111111111111111"
      "100100001111101011111111111000100111111111111110011111111111111111111111"
      "111111100001111111111111111111111111111001111111111111111111111111110100"
      "101111111111111111111111111111100111111111111111111111111101000111111111"
      "111111111111111111111110001111111111111111111111110001000111111111111111"
      "111111111111110000111111100111111111111111111101111111111111111111111111"
      "111111000001111111010111111111111111100011111111111111111111101111111000"
      "000111111100010001111111111100101111111111101111101000011111100000011111"
      "110101010010100011010110010100101100011000001011111110000000111111110001"
      "100000100000001100011000000101001110111111110000000001111111010011110111"
      "101110011100001110111110101111111110000000000111111111101001001000101111"
      "011101101000001000111111111000000000001111111100001101101000010001010000"
      "111010001111111111000000000000011111111101100011111011010100010110001111"
      "111111111000000000000001111111110011100101000111000101110010001111111111"
      "100000000000000011111111100011110001110110111101111011111111111100000000"
      "000000000111111111011000010100000010000101111111111111100000000000000000"
      "001111111111110101111011011010110011111111111100000000000000000000011111"
      "111111110000111100001000011111111111100000000000000000000000011111111111"
      "111111111011111111111111111000000000000000000000000000111111111111111111"
      "111111111111111111000000000000000000000000000000111111111111111111111111"
      "111111110000000000000000000000000000000001111111111111111111111111111110"
      "000000000000000000000000000000000000111111111111111111111111000000000000"
      "000000000000000000000000000000111111111111111111110000000000000000000000"
      "0000000000000000000000000011111111111100000000000000000000000000";
  int r, c;
  cin >> r >> c;
  cout << (a[r * 64 + c] == '1' ? "IN" : "OUT");
  return 0;
}
