#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  int arr[100100];
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
  }
  int count = 0;
  for (int i = n - 1; i >= 0; i--) {
    if (arr[i] == 0) {
      count++;
    } else
      break;
  }
  if (count == 1 || count >= 3) {
    cout << "YES\n";
    if (count == 1) {
      for (int i = 0; i < n; i++) {
        cout << arr[i];
        if (i != n - 1) cout << "->";
      }
    }
    if (count >= 3) {
      for (int i = 0; i < n; i++) {
        if (i == n - 3) {
          cout << "(";
        }
        cout << arr[i];
        if (i == n - 2) {
          cout << ")";
        }
        if (i != n - 1) cout << "->";
      }
    }
  } else {
    if (count == 0)
      cout << "NO\n";
    else {
      int z = 0;
      for (int i = 0; i < n; i++) {
        if (arr[i] == 0) {
          z++;
        }
      }
      if (z == 2) {
        cout << "NO\n";
      } else {
        cout << "YES\n";
        bool flag = false;
        for (int i = 0; i < n; i++) {
          if (!flag && arr[i] == 0) {
            cout << arr[i] << "->(";
            flag = true;
            continue;
          }
          cout << arr[i];
          if (i == n - 2) {
            cout << ")";
          }
          if (i != n - 1) cout << "->";
        }
      }
    }
  }
  return 0;
}
