#include <bits/stdc++.h>
using namespace std;
const int MaxN = 100000 + 10;
int n, arr[MaxN], az, ez;
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", &arr[i]);
    if (arr[i] == 0) ++az;
  }
  int p;
  for (p = n; p >= 1; --p)
    if (arr[p] != 0)
      break;
    else
      ++ez;
  if (ez == 0 || (ez == az && ez == 2))
    printf("NO\n");
  else {
    printf("YES\n");
    if (ez == az) {
      if (ez & 1) {
        for (int i = 1; i <= n - ez; ++i) printf("1->");
        for (int i = n - ez + 1; i < n; i += 2) printf("(0->0)->");
        printf("0\n");
      } else {
        for (int i = 1; i <= n - ez; ++i) printf("1->");
        printf("(0->(");
        for (int i = n - ez + 2; i < n - 2; ++i) printf("0->");
        printf("(0->0)");
        printf("))->0\n");
      }
    } else {
      for (p = 1; p <= n; ++p)
        if (arr[p] == 0) break;
      if (ez & 1) {
        for (int i = 1; i <= n - ez; ++i) {
          if (i == p) printf("(");
          printf("%d", arr[i]);
          if (i == n - ez) printf(")");
          printf("->");
        }
        for (int i = n - ez + 1; i < n; i += 2) printf("(0->0)->");
        printf("0\n");
      } else {
        for (int i = 1; i <= n - ez; ++i) {
          if (i == p + 1 || i == p) printf("(");
          if (i == p + 1) printf("(");
          printf("%d", arr[i]);
          if (i == n - ez) printf(")");
          printf("->");
        }
        printf("0))->");
        for (int i = n - ez + 2; i < n; i += 2) printf("(0->0)->");
        printf("0\n");
      }
    }
  }
  return 0;
}
