print("Jutge enters.")
stop = False
while not stop:
    ln = input().split()
    if ln[0] == "stop":
        stop = True
    elif ln[0] == "call":
        d = eval(input())
        ks = eval(input())
        print(cat_some(d, ks))
    elif ln[0] == "sum":
        d0 = eval(input())
        ks0 = eval(input())
        d1 = eval(input())
        ks1 = eval(input())
        print(cat_some(d0, ks0) + cat_some(d1, ks1))
print("Jutge exits.")