#include<bits/stdc++.h>
using namespace std;
int main()
{
long long n;
cin >> n;
while(1)
{
if(n % 2 == 0)
{
cout << n << '/' << 2 << '=';
n /= 2;
cout << n << endl;
if(n == 1)
{
cout << "End";
break;
}
}
else
{
cout << n << '*' << 3 << '+' << 1 << '=';
n = n * 3 + 1;
cout << n << endl;
if(n == 1)
{
cout << "End";
break;
}
}
}
return 0;
}