from itertools import product

A,B,C,D = list(eval(input()))

for k in list(product(['+','-'],repeat=3)):

    k = A + k[0] + B + k[1] + C + k[2] + D

    if eval(k) == 7:

        print(('{}=7'.format(k)))

        break
num_li = list(eval(input()))

for i in range(2**3):

    li = ['+']*3

    q = num_li[0]

    for j in range(3):

        if ((i>>j) & 1):

            li[j] = '-'

        q += li[j] + num_li[j+1]

    if eval(q) == 7:

        print(('{}=7'.format(q)))

        break
from itertools import product

A, B, C, D = list(eval(input()))
for k in list(product(["+", "-"], repeat=3)):
    k = A + k[0] + B + k[1] + C + k[2] + D
    if eval(k) == 7:
        print(("{}=7".format(k)))
        break

num_li = list(eval(input()))
for i in range(2**3):
    li = ["+"] * 3
    q = num_li[0]
    for j in range(3):
        if (i >> j) & 1:
            li[j] = "-"
        q += li[j] + num_li[j + 1]
    if eval(q) == 7:
        print(("{}=7".format(q)))
        break

-from itertools import product - -A, B, C, D = list(eval(input())) -for k in list(product(["+", "-"], repeat=3)): -    k = A + k[0] + B + k[1] + C + k[2] + D -    if eval(k) == 7: -        print(("{}=7".format(k))) +num_li = list(eval(input())) +for i in range(2**3): +    li = ["+"] * 3 +    q = num_li[0] +    for j in range(3): +        if (i >> j) & 1: +            li[j] = "-" +        q += li[j] + num_li[j + 1] +    if eval(q) == 7: +        print(("{}=7".format(q)))