#include <bits/stdc++.h>
using namespace std;
int n, m;
char mat[55][55];
bool vis[55][55];
bitset<55> r, c;
bool band = true;
void visitar(int y, int x) {
  if (vis[y][x]) return;
  vis[y][x] = true;
  r[y] = c[x] = true;
  for (int i = x + 1; i < n; ++i) {
    if (c[i] && mat[y][i] != '#') band = false;
    if (mat[y][i] == '#') {
      visitar(y, i);
      break;
    }
  }
  for (int i = y + 1; i < n; ++i) {
    if (r[i] && mat[i][x] != '#') band = false;
    if (mat[i][x] == '#') {
      visitar(i, x);
      break;
    }
  }
  for (int i = x - 1; i >= 0; --i) {
    if (c[i] && mat[y][i] != '#') band = false;
    if (mat[y][i] == '#') {
      visitar(y, i);
      break;
    }
  }
  for (int i = y - 1; i >= 0; --i) {
    if (r[i] && mat[i][x] != '#') band = false;
    if (mat[i][x] == '#') {
      visitar(i, x);
      break;
    }
  }
}
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  cin >> n >> m;
  for (int i = 0; i < n; ++i) {
    for (int j = 0; j < m; ++j) {
      cin >> mat[i][j];
    }
  }
  for (int i = 0; i < n; ++i) {
    for (int j = 0; j < m; ++j) {
      if (mat[i][j] == '#') {
        visitar(i, j);
        r.reset();
        c.reset();
      }
    }
  }
  if (!band)
    cout << "NO\n";
  else
    cout << "YES\n";
  return 0;
}
