#include <bits/stdc++.h>
using namespace std;
int main() {
  int h, n;
  cin >> n >> h;
  for (int i = 1; i <= n; i++) {
    if (i % 2 == 1) {
      for (int j = 1; j <= h; j++) {
        cout << "#";
      }
    } else {
      if ((i / 2) % 2 == 1) {
        for (int j = 1; j <= h - 1; j++) {
          cout << ".";
        }
        cout << "#";
      } else {
        cout << "#";
        for (int j = 1; j <= h - 1; j++) {
          cout << ".";
        }
      }
    }
    cout << endl;
  }
  return 0;
}
