#include <iostream>
#include <cstdlib>

using namespace std;

const static int OPERAND_N = 4;
const static int OPECODE_N = OPERAND_N - 1;
const static int OPECODE_TYPE_N = 3;
const static char OP[ OPECODE_TYPE_N ] = { '+', '-', '*' };
const static int OP_ADD = 0;
const static int OP_SUB = 1;
const static int OP_MUL = 2;
const static int EXP_CENTER = 0;
const static int EXP_LEFTMOST = 1;
const static int OBJ_SUM = 10;

namespace rec_data {
  int history[ OPERAND_N ] = { 0 };
  int perm_opr[ OPERAND_N ];
  int perm_opc[ OPECODE_N ];
};

bool rec_opc( int n, int operands[ OPERAND_N ], int expType ) {
  using namespace rec_data;
  if( n == 0 ) {
    for( int i = 0; i < OPECODE_N; i++ ) {
      perm_opc[ i ] = -1;
    }
  } else if( n == OPERAND_N ) {
    int p = operands[ perm_opr[ 0 ] ];
    int q = operands[ perm_opr[ 1 ] ];
    int r = operands[ perm_opr[ 2 ] ];
    int s = operands[ perm_opr[ 3 ] ];
    if( expType == EXP_CENTER ) {
      int left, right, ans;
      if( perm_opc[ 0 ] == OP_ADD ) { 
        left = p + q;
      } else if( perm_opc[ 0 ] == OP_SUB ) {
        left = p - q;
      } else {
        left = p * q;
      }
      if( perm_opc[ 2 ] == OP_ADD ) { 
        right = r + s;
      } else if( perm_opc[ 2 ] == OP_SUB ) {
        right = r - s;
      } else {
        right = r * s;
      }
      if( perm_opc[ 1 ] == OP_ADD ) { 
        ans = left + right ;
      } else if( perm_opc[ 1 ] == OP_SUB ) {
        ans = left - right;
      } else {
        ans = left - right;
      }
      if( ans == OBJ_SUM ) {
        cout << "(" << p << " " << OP[ perm_opc[ 0 ] ] << " " <<
          q << ") " << OP[ perm_opc[ 1 ] ] << " (" << r << " " <<
          OP[ perm_opc[ 2 ] ] << " " << s << ")" << endl;
        return true;
      }
      return false;
    } else { // LEFTMOST
      int left, center, ans;
      if( perm_opc[ 0 ] == OP_ADD ) { 
        left = p + q;
      } else if( perm_opc[ 0 ] == OP_SUB ) {
        left = p - q;
      } else {
        left = p * q;
      }
      if( perm_opc[ 1 ] == OP_ADD ) { 
        center = left + r;
      } else if( perm_opc[ 1 ] == OP_SUB ) {
        center = left - r;
      } else {
        center = left * r;
      }
      if( perm_opc[ 2 ] == OP_ADD ) { 
        ans = center + s ;
      } else if( perm_opc[ 2 ] == OP_SUB ) {
        ans = center - s;
      } else {
        ans = center * s;
      }
      if( ans == OBJ_SUM ) {
        cout << "((" << p << " " << OP[ perm_opc[ 0 ] ] << " " <<
          q << ") " << OP[ perm_opc[ 1 ] ] << " " << r << ") " <<
          OP[ perm_opc[ 2 ] ] << " " << s << endl;
        return true;
      }
      return false; 
    }
    return false;
  }
  for( int i = 0; i < OPECODE_N; i++ ) {
    perm_opc[ n ] = i;
    bool found = rec_opc( n + 1, operands, expType );
    perm_opc[ n ] = -1;
    if( found ) { return true; }
  }
  return false;
}

bool rec_opr( int n, int operands[ OPERAND_N ], int expType  ) {
  using namespace rec_data;
  if( n == 0 ) {
    for( int i = 0; i < OPERAND_N; i++ ) {
      perm_opr[ i ] = -1;
    }
  } else if( n == OPERAND_N ) {
    return rec_opc( 0, operands, expType );
  }
  for( int i = 0; i < OPERAND_N; i++ ) {
    if( history[ i ] ) { continue; }
    perm_opr[ n ] = i;
    history[ i ] = 1;
    bool found = rec_opr( n + 1, operands, expType );
    history[ i ] = 0;
    perm_opr[ n ] = -1;
    if( found ) { return true; }
  }
  return false;
}

int main () {
  while( 1 ) {
    int operands[ OPERAND_N ];
    cin >> operands[ 0 ] >> operands[ 1 ] >> operands[ 2 ] >> operands[ 3 ];
    if(
        !( operands[ 0 ] | operands[ 1 ] | operands[ 2 ] | operands[ 3 ] )
    ){ break; }

    // ( # ? # ) ? ( # ? # )
    bool found = rec_opr( 0, operands, EXP_CENTER );
    if( found ) { continue; }

    // ( ( # ? # ) ? # ) ? #
    found = rec_opr( 0, operands, EXP_LEFTMOST );
    if( found ) { continue; }
    cout << "0" << endl; 
  }

}