#include <bits/stdc++.h>
const int maxn = 10000050;
using namespace std;
char a[1005][6];
void solve() {
  memset(a, 0, sizeof(a));
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) cin >> a[i];
  int flag = 0;
  for (int i = 0; i < n; i++) {
    if (a[i][0] == 'O' && a[i][1] == 'O') {
      a[i][0] = '+', a[i][1] = '+';
      flag = 1;
      break;
    }
    if (a[i][3] == 'O' && a[i][4] == 'O') {
      a[i][3] = '+', a[i][4] = '+';
      flag = 1;
      break;
    }
  }
  if (flag) {
    cout << "YES" << endl;
    for (int i = 0; i < n; i++) cout << a[i] << endl;
  } else
    cout << "NO" << endl;
}
int main() { solve(); }
