<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>
using namespace std;
vector<string> s = {
    "1111111111111111111111111101010000001011111111111111111111111111",
    "1111111111111111111111010001010101101000001111111111111111111111",
    "1111111111111111111100010111011100101111011011111111111111111111",
    "1111111111111111100001010100000111100001010001011111111111111111",
    "1111111111111111001111110101111100001111010101001111111111111111",
    "1111111111111101100100000100010001011010011101101011111111111111",
    "1111111111111000110110111111010111000011001001001001111111111111",
    "1111111111100000010010010001000100011110011011011100011111111111",
    "1111111111000000000000111101111101110100110010010110001111111111",
    "1111111110000000000000000000010000000110000110000000000111111111",
    "1111111100000000000000000000000000000000000000000000000011111111",
    "1111111000000000000000000000000000000000000000000000000001111111",
    "1111111000000000000000000000000000000000000000000000000001111111",
    "1111110000000000000000000000000000000000000000000000000000111111",
    "1111100000000000000000000000000000000000000000000000000000011111",
    "1111100000000000000000000000000000000000000000000000000000011111",
    "1111000000000000000000000000000000000000000000000000000000001111",
    "1110000000000000000000000000000000000000000000000000000000000111",
    "1111100000000000000000000000000000000000000000000000000000000111",
    "1111111000000000000111011000000000000001110101000000000000011111",
    "1100111110000000001101110000000000000001011111110000000011111111",
    "1100001111100000111001011100000000000000010010011010011111110011",
    "1000000011111011100011000110000000000010110111001111111110000001",
    "1000000000111110110110010011100000000010010000011011110000000001",
    "1000000000000100100011111000110000000111011011110001000000000001",
    "1000000000111110111000100011100000000101000001011101101000000001",
    "0000000000001000101101101110110000001101101111001000111000000000",
    "0000000000011101101001000100010000101000100001100011101000000000",
    "0000000000010000001000011110110101111010110100001110001000000000",
    "0000000000011111011011000100011101010010010110111011011000000000",
    "0000000000001001000010010001110100011111000010100000010000000000",
    "0000000000011100011011011100010110001000011010001110111000000000",
    "0000000000000111110010001001000100111110110010011011101000000000",
    "0000000000000010010111101011110101101010010111001001000000000000",
    "0000000000001111000010101010100001001011010001100011100000000000",
    "0000000000000101101110001110000111011001111011001110000000000000",
    "0000000000000000111000111010010010010011010001011011000000000000",
    "0000000000000000001110100000011111000000011101110000000000000000",
    "1000000000000000011011110000010100000000000111011000000000000001",
    "1000000000000000000000000000000111100000000000000000000000000001",
    "1000000000000000000000000000101101000000000000000000000000000001",
    "1000000000000000000000000010111000000000000000000000000000000001",
    "1100000000000000000000000011101110000000000000000000000000000011",
    "1100000001100000000000000000001000000000000000000000000000000011",
    "1110000000101000000000000000011100000000000000000000010000000111",
    "1110000000111011100000000000110100000000000100000101111000000111",
    "1110000000101010110101110010100110101101001110011111010000000111",
    "1111000000001110011111011111110011100111111010110001000000001111",
    "1111100000001011000010000100011000111100010000010100000000011111",
    "1111100000000001011011011101000010001001011111011100000000011111",
    "1111110000000011110010010111101110101111000101110000000000111111",
    "1111111000000000100111000001001010111010011100000000000001111111",
    "1111111000000000110001101011100011101000110111000000000001111111",
    "1111111100000000011100001110001001000010000100000000000011111111",
    "1111111110000000001001111010111111011110100000000000000111111111",
    "1111111111000000000000101000010010010100110000000000001111111111",
    "1111111111100000000000001111000011110111100000000000011111111111",
    "1111111111111000000000000000000001000000000000000001111111111111",
    "1111111111111100000000000000000000000000000000000011111111111111",
    "1111111111111111000000000000000000000000000000001111111111111111",
    "1111111111111111100000000000000000000000000000011111111111111111",
    "1111111111111111111100000000000000000000000011111111111111111111",
    "1111111111111111111111000000000000000000001111111111111111111111",
    "1111111111111111111111111100000000000011111111111111111111111111"};
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int x, y;
  cin >> x >> y;
  if (s[x][y] == '1')
    cout << "OUT" << endl;
  else
    cout << "IN" << endl;
}
