#include <bits/stdc++.h>
using namespace std;
char mapp[55][55];
char change[4][2] = {1, 0, 2, 0, 1, -1, 1, 1};
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%s", mapp[i]);
  }
  bool flag = true;
  for (int i = 0; i < n; i++) {
    for (int k = 0; k < n; k++) {
      if (mapp[i][k] == '.') {
        mapp[i][k] = '#';
        for (int j = 0; j < 4; j++) {
          int tempx = i + change[j][0];
          int tempy = k + change[j][1];
          if (tempx < 0 || tempx >= n || tempy < 0 || tempy >= n ||
              mapp[tempx][tempy] != '.') {
            flag = false;
            break;
          } else
            mapp[tempx][tempy] = '#';
        }
        if (!flag) break;
      }
    }
  }
  if (flag)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
