#include <bits/stdc++.h>
using namespace std;
int main() {
  int col, row;
  int r, t;
  cin >> r;
  cin >> t;
  if (r % 2 == 0 && r != t) {
    col = r;
    row = t;
  } else {
    col = t;
    row = r;
  }
  char** arr;
  arr = new char*[row];
  for (int i = 0; i < row; i++) arr[i] = new char[col];
  for (int a = 0; a < row; a++) {
    for (int b = 0; b < col; b++) {
      arr[a][b] = '.';
    }
  }
  for (int m = 0; m < row;) {
    for (int j = 0; j < col; j++) {
      arr[m][j] = '#';
    }
    m += 2;
  }
  int k = 0;
  for (int h = 1; h < row;) {
    {
      if (k % 2 == 0) {
        arr[h][col - 1] = '#';
      } else
        arr[h][0] = '#';
    }
    h += 2;
    k++;
  }
  for (int a = 0; a < row; a++) {
    for (int b = 0; b < col; b++) {
      cout << arr[a][b];
    }
    cout << endl;
  }
  for (int i = 0; i < row; i++) delete[] arr[i];
  delete[] arr;
  return 0;
}
