#include <bits/stdc++.h>
using namespace std;
char A[250][250], B[250][250], C[250][250];
int N;
vector<pair<int, int> > L;
vector<pair<int, int> > M;
int main() {
  scanf("%d", &N);
  for (int i = 0; i < N; i++) scanf("%s", A[i]);
  for (int i = 0; i < N; i++)
    for (int j = 0; j < N; j++)
      if (A[i][j] == 'o') L.push_back({i, j});
  for (int i = -N + 1; i <= N - 1; i++)
    for (int j = -N + 1; j <= N - 1; j++) {
      bool ok = 1;
      for (int k = 0; k < L.size(); k++) {
        if (L[k].first + i < 0 || L[k].first + i > N - 1) continue;
        if (L[k].second + j < 0 || L[k].second + j > N - 1) continue;
        if (A[L[k].first + i][L[k].second + j] == '.') ok = 0;
      }
      if (ok) M.push_back({i, j});
    }
  for (int i = 0; i < L.size(); i++) {
    for (int j = 0; j < M.size(); j++) {
      if (L[i].first + M[j].first < 0 || L[i].first + M[j].first > N - 1)
        continue;
      if (L[i].second + M[j].second < 0 || L[i].second + M[j].second > N - 1)
        continue;
      B[L[i].first + M[j].first][L[i].second + M[j].second] = 'x';
    }
  }
  for (int i = 0; i < N; i++)
    for (int j = 0; j < N; j++)
      if (A[i][j] == '.' && B[i][j] == 'x') {
        printf("NO\n");
        return 0;
      }
  for (int i = 0; i < N; i++)
    for (int j = 0; j < N; j++)
      if (A[i][j] == 'x' && B[i][j] == 0) {
        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++) C[i][j] = '.';
  for (int i = 0; i < M.size(); i++) {
    C[M[i].first + N - 1][M[i].second + N - 1] = 'x';
  }
  C[N - 1][N - 1] = 'o';
  for (int i = 0; i < 2 * N - 1; i++) {
    for (int j = 0; j < 2 * N - 1; j++) printf("%c", C[i][j]);
    printf("\n");
  }
  return 0;
}
