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