#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int n, i, j;
  char a[1100][10];
  while (scanf("%d", &n) == 1) {
    int f = 0;
    for (i = 0; i < n; i++) {
      scanf("%s", a[i]);
      if (f) continue;
      if (a[i][0] == 'O' && a[i][1] == 'O') {
        f = 1;
        a[i][0] = a[i][1] = '+';
      } else if (a[i][3] == 'O' && a[i][4] == 'O') {
        f = 1;
        a[i][3] = a[i][4] = '+';
      }
    }
    if (f) {
      printf("YES\n");
      for (i = 0; i < n; i++) printf("%s\n", a[i]);
    } else
      printf("NO\n");
  }
}
