#include <bits/stdc++.h>
using namespace std;
const long double eps = 1e-9;
const int maxn = 3e2;
const long long inf = 1e9 + 7;
vector<pair<int, int> > f, u, ho;
string s[100];
int used[10000];
int n;
bool check(int dx, int dy) {
  for (int i = 0; i < f.size(); ++i) {
    if (f[i].first + dx >= 0 && f[i].first + dx < n && f[i].second + dy >= 0 &&
        f[i].second + dy < n) {
      if (s[f[i].first + dx][f[i].second + dy] == '.') return false;
    }
  }
  return true;
}
int main() {
  cin >> n;
  for (int i = 0; i < n; ++i) {
    cin >> s[i];
  }
  for (int i = 0; i < n; ++i) {
    for (int j = 0; j < n; ++j) {
      if (s[i][j] == 'o') {
        f.push_back(make_pair(i, j));
      }
      if (s[i][j] == 'x') {
        u.push_back(make_pair(i, j));
      }
    }
  }
  for (int i = 0; i < u.size(); ++i) {
    int s = ho.size();
    for (int j = 0; j < f.size(); ++j) {
      if (check(u[i].first - f[j].first, u[i].second - f[j].second)) {
        ho.push_back(
            make_pair(u[i].first - f[j].first, u[i].second - f[j].second));
        break;
      }
    }
    if (s == ho.size()) {
      cout << "NO";
      return 0;
    }
  }
  cout << "YES\n";
  string ss[300];
  for (int i = 0; i < 2 * n - 1; ++i) {
    for (int j = 0; j < 2 * n - 1; ++j) {
      ss[i] += ".";
    }
  }
  ss[n - 1][n - 1] = 'o';
  for (int i = 0; i < ho.size(); ++i) {
    ss[n - 1 + ho[i].first][n - 1 + ho[i].second] = 'x';
  }
  for (int i = 0; i < 2 * n - 1; ++i) {
    cout << ss[i] << endl;
  }
  return 0;
}
