#include <bits/stdc++.h>
using namespace std;
char a[1010][6];
int n;
int main() {
  cin >> n;
  bool flag = false;
  for (int i = 0; i < n; i++) {
    scanf("%s", a[i]);
    if (flag) continue;
    if (a[i][0] == a[i][1] && a[i][0] == 'O') {
      flag = true;
      a[i][0] = a[i][1] = '+';
      continue;
    }
    if (a[i][3] == a[i][4] && a[i][3] == 'O') {
      flag = true;
      a[i][3] = a[i][4] = '+';
      continue;
    }
  }
  if (flag) {
    cout << "YES" << endl;
    for (int i = 0; i < n; i++) {
      printf("%s\n", a[i]);
    }
  } else
    cout << "NO" << endl;
  return 0;
}
