# 洛谷P1236 算24点

#include <bits/stdc++.h>
using namespace std;
struct step{
int a, b, ans;
char c;
}sta[10010];
int a[1001], vis[1000], flag;
bool check()
{
for (int i = 1; i <= 4; i++)
if (a[i] == 24) return 1;
return 0;
}
void print()
{
for (int i = 1; i <= 3; i++)//一定有三步，
{
if (sta[i].a < sta[i].b) swap(sta[i].a, sta[i].b);
printf("%d%c%d=%d\n", sta[i].a, sta[i].c, sta[i].b, sta[i].ans);
}
}
void dfs(int now)
{
if (now == 4)
{
if (check())
flag = 1, print(), exit(0);
return;
}
int temp1, temp2;
for (int i = 1; i <= 4; i++)
for (int j = 1; j <= 4; j++)
{
if (i == j || a[i] <= 0 || a[j] <= 0)
continue;
if (a[i] < a[j]) continue;
//加
sta[now].a = a[i], sta[now].b = a[j];
sta[now].c = '+', sta[now].ans = a[i] + a[j];
temp1 = a[j], temp2 = a[i];
a[i] = sta[now].ans;
a[j] = -1;
dfs(now + 1);
a[j] = temp1;
a[i] = temp2;
//减
sta[now].a = a[i], sta[now].b = a[j];
sta[now].c = '-', sta[now].ans = a[i] - a[j], temp1 = a[j], temp2 = a[i];
a[i] = sta[now].ans;
a[j] = -1;
dfs(now + 1);
a[j] = temp1;
a[i] = temp2;
//乘
sta[now].a = a[i], sta[now].b = a[j];
sta[now].c = '*', sta[now].ans = a[i] * a[j], temp1 = a[j], temp2 = a[i];
a[i] = sta[now].ans;
a[j] = -1;
dfs(now + 1);
a[j] = temp1;
a[i] = temp2;
//除
if (a[j] != 0 && a[i] % a[j] == 0)
{
sta[now].a = a[i], sta[now].b = a[j];
sta[now].c = '/', sta[now].ans = a[i] / a[j], temp1 = a[j], temp2 = a[i];
a[i] = sta[now].ans;
a[j] = -1;
dfs(now + 1);
a[j] = temp1;
a[i] = temp2;
}
}
}
int main()
{
scanf("%d%d%d%d", &a[1], &a[2], &a[3], &a[4]);
dfs(1);