#include <bits/stdc++.h>
using namespace std;
string str[1023];
int main() {
  int n, i, j, k, r = 0, c, flag = 0;
  cin >> n;
  for (i = 1; i <= n; i++) {
    cin >> str[i];
    for (j = 0; j < str[i].size() - 1; j++) {
      if (str[i][j] == 'O' && str[i][j] == str[i][j + 1] && flag == 0) {
        r = i;
        str[i][j] = '+', str[i][j + 1] = '+';
        flag = 1;
      }
    }
  }
  if (r != 0) {
    cout << "YES" << endl;
    for (i = 1; i <= n; i++) {
      cout << str[i] << endl;
    }
  } else
    cout << "NO" << endl;
  return 0;
}
