#include <bits/stdc++.h>
using namespace std;
long long MOD = 1000000007;
long long N;
bool isInside(long long x, long long y) {
  return x >= 0 && x < N && y >= 0 && y < N;
}
signed main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  cin >> N;
  vector<string> A(N);
  vector<string> B(N, string(N, '.'));
  long long res = 0;
  for (long long i = 0; i < N; i++) {
    cin >> A[i];
  }
  set<pair<long long, long long> > st;
  for (long long i = -(N - 1); i <= N - 1; i++) {
    for (long long j = -(N - 1); j <= N - 1; j++) {
      st.emplace(i, j);
    }
  }
  for (long long x = 0; x < N; x++) {
    for (long long y = 0; y < N; y++) {
      if (A[x][y] == 'o') {
        for (long long xx = 0; xx < N; xx++) {
          for (long long yy = 0; yy < N; yy++) {
            if (A[xx][yy] == '.') {
              st.erase(make_pair(xx - x, yy - y));
            }
          }
        }
      }
    }
  }
  vector<pair<long long, long long> > vp;
  for (auto s : st) {
    vp.push_back(s);
  }
  for (long long i = 0; i < N; i++) {
    for (long long j = 0; j < N; j++) {
      if (A[i][j] == 'o') {
        B[i][j] = 'o';
        for (pair<long long, long long> p : vp) {
          long long xx = i + p.first;
          long long yy = j + p.second;
          if (isInside(xx, yy)) {
            if (A[xx][yy] != 'o') {
              B[xx][yy] = 'x';
            }
          }
        }
      }
    }
  }
  bool ok = true;
  for (long long i = 0; i < N; i++) {
    if (A[i] != B[i]) {
      ok = false;
    }
  }
  if (ok) {
    vector<string> res(2 * N - 1, string(2 * N - 1, '.'));
    for (pair<long long, long long> p : vp) {
      res[p.first + N - 1][p.second + N - 1] = 'x';
    }
    res[N - 1][N - 1] = 'o';
    cout << "YES" << endl;
    for (long long i = 0; i < res.size(); i++) {
      cout << res[i] << endl;
    }
  } else {
    cout << "NO" << endl;
  }
}
