str1 = '1 2 3 4 5 6 7 8 9 0'
while True:
    try:
        #获取输入的两个字符串
        x1 = input()
        x2 = input()
        #定义标签来判断输入数据是否合法
        flag = 0
        if len(x1) > 10000 or len(x2) > 10000:
            flag = 1
        for word in x1:
            if word not in str1:
                flag = 1
        for word in x2:
            if word not in str1:
                flag = 1
        if flag == 1:
            break
        ans = int(x1) + int(x2)
        print(ans)
    except:
        break