#include <bits/stdc++.h>
using namespace std;
const int MXN = 64;
char inp[MXN][MXN];
char res[MXN * 2][MXN * 2];
int n;
bool solve() {
  memset(res, 'x', sizeof(res));
  res[n - 1][n - 1] = 'o';
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (inp[i][j] != 'o') continue;
      for (int ti = 0; ti < n; ti++) {
        for (int tj = 0; tj < n; tj++) {
          if (inp[ti][tj] != '.') continue;
          res[n - 1 + (ti - i)][n - 1 + (tj - j)] = '.';
        }
      }
    }
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (inp[i][j] != 'x') continue;
      bool good = false;
      for (int ti = 0; ti < n; ti++) {
        for (int tj = 0; tj < n; tj++) {
          if (inp[ti][tj] != 'o') continue;
          if (res[n - 1 - (ti - i)][n - 1 - (tj - j)] == 'x') good = true;
        }
      }
      if (!good) return false;
    }
  }
  return true;
}
int main() {
  while (scanf("%d", &n) == 1) {
    for (int i = 0; i < n; i++) scanf("%s", inp[i]);
    if (solve()) {
      printf("YES\n");
      for (int i = 0; i < 2 * n - 1; i++) {
        res[i][2 * n - 1] = 0;
        puts(res[i]);
      }
    } else {
      printf("NO\n");
    }
  }
  return 0;
}
