#include <bits/stdc++.h>
using namespace std;
void printa() { cout << endl; }
template <class T, class... A>
void printa(const T& first, const A&... rest) {
  cout << first;
  printa(rest...);
}
template <class... A>
void printa(const A&... rest) {
  printa(rest...);
}
int factorial(int x) {
  int f = 1;
  for (int i = 1; i < x + 1; i++) f = f * i;
  return f;
}
int sigma(int x) {
  int s;
  for (int i = 1; i < x + 1; i++) s = s + i;
  return s;
}
int middle(int x) {
  if (x % 2 == 0)
    return x / 2;
  else
    return x / 2 + 1;
}
int main(void) {
  int a, b;
  cin >> a >> b;
  string box[a];
  for (int i = 0; i < a; i++) {
    cin >> box[i];
  }
  for (int i = 0; i < a; i++) {
    if (box[i].find("##") != string::npos) {
    }
  }
  return 0;
}
