import itertools


def fun(arr, y):

    # 前面的结果与后一个数加减乘除的可能
    res = []
    for x in arr:
        res.append(x)
        res.append(y)
        res.append(x + y)
        res.append(x - y)
        res.append(x * y)
        res.append(x / y)
    return res


while True:
    
    try:
        num_list = [int(i) for i in input().split()]
        
        # 存放所有加减乘除的可能
        result_list = []
        # 所有数字排列的顺序都考虑进去
        for i in range(len(list(itertools.permutations(num_list)))):
            a, b, c, d = list(itertools.permutations(num_list))[i]
            list1 = fun([a], b)
            list2 = fun(list1, c)
            list3 = fun(list2, d)
            result_list.extend(list3)
        # 只要24在所有的结果中就满足条件
        if 24 in result_list:
            print('true')
        else:
            print('false')
        
    except:
        break