#include <bits/stdc++.h>
using namespace std;
string G[55];
bool ok[2 * 55][2 * 55];
int main() {
  int n;
  scanf("%d", &n);
  int LIM = n - 1;
  for (int i = 0; i < n; i++) cin >> G[i];
  for (int i = 0; i < 2 * n - 1; i++)
    for (int j = 0; j < 2 * n - 1; j++) ok[i][j] = 1;
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (G[i][j] != 'o') continue;
      for (int dx = -LIM; dx <= LIM; dx++) {
        for (int dy = -LIM; dy <= LIM; dy++) {
          if (i + dx < 0) continue;
          if (j + dy < 0) continue;
          if (i + dx >= n) continue;
          if (j + dy >= n) continue;
          if (G[i + dx][j + dy] == '.') ok[LIM + dx][LIM + dy] = 0;
        }
      }
    }
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      if (G[i][j] != 'x') continue;
      bool found = 0;
      for (int dx = -LIM; dx <= LIM; dx++) {
        for (int dy = -LIM; dy <= LIM; dy++) {
          if (!ok[LIM + dx][LIM + dy]) continue;
          if (i - dx < 0) continue;
          if (j - dy < 0) continue;
          if (i - dx >= n) continue;
          if (j - dy >= n) continue;
          if (G[i - dx][j - dy] != 'o') continue;
          found = 1;
        }
      }
      if (!found) {
        printf("NO\n");
        return 0;
      }
    }
  }
  printf("YES\n");
  for (int i = 0; i < 2 * n - 1; i++) {
    for (int j = 0; j < 2 * n - 1; j++) {
      if (i == LIM && j == LIM)
        printf("o");
      else if (ok[i][j])
        printf("x");
      else
        printf(".");
    }
    printf("\n");
  }
}
