<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
import java.io.*;
import java.math.BigInteger;
import java.util.*;

/*
Прокрастинирую
*/

public class Main {

    static FastReader in;
    static PrintWriter out;
    static Random rand = new Random();
    static final int INF = (int) (1e9 + 10), MOD = (int) (998244353), LOGN = 20;
    static final long IINF = (long) (2e18 + 10);
    static int[][] data = {
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216},
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       },
        {-1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       },
        {-1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       },
        {-1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       },
        {-1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       },
        {-1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -1       , -1       , -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -16777216, -1       , -16777216, -1       , -16777216, -16777216, -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -16777216, -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
        {-1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -16777216, -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       , -1       },
    };

    static void solve() {
        int row = in.nextInt();
        int col = in.nextInt();

        if (data[row][col] == -1) {
            out.println("OUT");
        } else {
            out.println("IN");
        }
    }

    public static void main(String[] args) throws FileNotFoundException {
        in = new FastReader(System.in);
//        in = new FastReader(new FileInputStream("sometext.txt"));
        out = new PrintWriter(System.out);
//        out = new PrintWriter(new FileOutputStream("sometext.txt"));

        int tests = 1;
//        tests = in.nextInt();

        while (tests-- > 0) {
            solve();
        }

//        out.flush();
        out.close();
    }

    static class FastReader {
        BufferedReader br;
        StringTokenizer st;

        FastReader(InputStream is) {
            br = new BufferedReader(new InputStreamReader(is));
        }

        Integer nextInt() {
            return Integer.parseInt(next());
        }

        Long nextLong() {
            return Long.parseLong(next());
        }

        Double nextDouble() {
            return Double.parseDouble(next());
        }

        String next() {
            while (st == null || !st.hasMoreTokens()) {
                st = new StringTokenizer(nextLine());
            }
            return st.nextToken();
        }

        String nextLine() {
            String s = "";
            try {
                s = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return s;
        }
    }
}