#include <bits/stdc++.h>
using namespace std;
char s[55];
char ans[105][105];
int n, a[55][55], v[55][55], no[105][105];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%s", s);
    for (int j = 1; j <= n; j++) {
      if (s[j - 1] == '.') a[i][j] = 0;
      if (s[j - 1] == 'x') a[i][j] = 2;
      if (s[j - 1] == 'o') a[i][j] = 1;
    }
  }
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= n; j++)
      if (a[i][j] == 1) {
        for (int x = 1; x <= n; x++)
          for (int y = 1; y <= n; y++)
            if (a[x][y] == 0) no[x - i + 50][y - j + 50] = 1;
      }
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= n; j++)
      if (a[i][j] == 1) {
        for (int x = 0; x <= 100; x++)
          for (int y = 0; y <= 100; y++) {
            if (no[x][y]) continue;
            int p = i + x - 50, q = j + y - 50;
            if (p > 0 && q > 0 && p <= n && q <= n) v[p][q] = 1;
          }
      }
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= n; j++)
      if (a[i][j] == 2 && !v[i][j]) {
        cout << "NO" << endl;
        return 0;
      }
  cout << "YES" << endl;
  int N = 2 * n - 1;
  for (int i = 1; i <= N; i++)
    for (int j = 1; j <= N; j++) ans[i][j] = '.';
  for (int x = 0; x <= 100; x++)
    for (int y = 0; y <= 100; y++) {
      if (no[x][y]) continue;
      int p = x - 50 + n, q = n + y - 50;
      if (p > 0 && q > 0 && p <= N && q <= N) ans[p][q] = 'x';
    }
  ans[n][n] = 'o';
  for (int i = 1; i <= N; i++) {
    for (int j = 1; j <= N; j++) printf("%c", ans[i][j]);
    printf("\n");
  }
  return 0;
}
