#include <bits/stdc++.h>
using namespace std;
int main() {
  int a;
  cin >> a;
  string cas = "NO", hhh[a];
  for (int i = 0; i < a; i++) {
    cin >> hhh[i];
    if (hhh[i].substr(0, 2) == "OO" && cas == "NO") {
      cas = "YES";
      hhh[i][0] = hhh[i][1] = '+';
    } else if (hhh[i].substr(3, 2) == "OO" && cas == "NO") {
      cas = "YES";
      hhh[i][3] = hhh[i][4] = '+';
    }
  }
  cout << cas << "\n";
  if (cas == "NO") return 0;
  for (int i = 0; i < a; i++) {
    cout << hhh[i] << "\n";
  }
  return 0;
}
