#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  cin >> n >> m;
  string hf = "", hl = "", hr = "";
  for (int i = 0; i < m; i++) {
    hf = hf + "#";
    hl = hl + ".";
  }
  hr = hl;
  hl[0] = '#';
  hr[m - 1] = '#';
  for (int i = 0; i < n; i++) {
    if (i % 2 == 0)
      cout << hf << endl;
    else if (i % 4 == 1)
      cout << hr << endl;
    else
      cout << hl << endl;
  }
  return 0;
}
