#include <bits/stdc++.h>
using namespace std;
int n;
char arr[1002][7];
bool sit = false;
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%s", arr[i]);
    if (!sit) {
      if (arr[i][0] == 'O' && arr[i][1] == 'O') {
        sit = true;
        arr[i][0] = arr[i][1] = '+';
      } else if (arr[i][3] == 'O' && arr[i][4] == 'O') {
        sit = true;
        arr[i][3] = arr[i][4] = '+';
      }
    }
  }
  if (sit) {
    printf("YES\n");
    for (int i = 0; i < n; i++) printf("%s\n", arr[i]);
  } else
    printf("NO\n");
  return 0;
}
