Problem: <image>

Input

The input contains two integers a1, a2 (0 ≤ ai ≤ 32), separated by a single space.

Output

Output a single integer.

Examples

Input

1 1


Output

0


Input

3 7


Output

0


Input

13 10


Output

1

Solution (in JAVA):

Solution:
import java.util.*;
import java.io.*;
import java.math.BigInteger;
public class AprA{
    static BufferedReader br;
    public static void main(String args[])throws Exception{
        br=new BufferedReader(new InputStreamReader(System.in));
        String st[]=toStrArray();
        int al=st[0].length();
        int bl=st[1].length();
        String a=st[0];
        String b=st[1];
        
        StringBuilder sb = new StringBuilder(b);
        sb=sb.reverse();
        b=sb.toString();
        if(al>bl){
            for(int i=0;i<al-bl;i++){
                b="0"+b;
            }
        }
        else if(bl>al){
            for(int i=0;i<bl-al;i++){
                a="0"+a;
            }
        }
        String res="";
        int mem=0;
        for(int i=a.length()-1;i>=0;i--){
            int t=mem+a.charAt(i)-'0'+b.charAt(i)-'0';
            mem=t/10;
            res=t%10+res;
        }
        res=mem+res;
        System.out.println(Integer.parseInt(res));

    }


    /****************************************************************/
    public static int[] toIntArray()throws Exception{
       String str[]=br.readLine().split(" ");
       int k[]=new int[str.length];
       for(int i=0;i<str.length;i++){
            k[i]=Integer.parseInt(str[i]);
       }
       return k;
    }
    public static int toInt()throws Exception{
       return Integer.parseInt(br.readLine());
    }
    public static long[] toLongArray()throws Exception{
       String str[]=br.readLine().split(" ");
       long k[]=new long[str.length];
       for(int i=0;i<str.length;i++){
            k[i]=Long.parseLong(str[i]);
       }
       return k;
    }
    public static long toLong()throws Exception{
       return Long.parseLong(br.readLine());
    }
    public static double[] toDoubleArray()throws Exception{
       String str[]=br.readLine().split(" ");
       double k[]=new double[str.length];
       for(int i=0;i<str.length;i++){
            k[i]=Double.parseDouble(str[i]);
       }
       return k;
    }
    public static double toDouble()throws Exception{
       return Double.parseDouble(br.readLine());
    }
    public static String toStr()throws Exception{
       return br.readLine();
    }
    public static String[] toStrArray()throws Exception{
       String str[]=br.readLine().split(" ");
       return str;
    }
    /****************************************************************/

}