import sys from copy import deepcopy sys.setrecursionlimit(10 ** 6) def main(): h, w = map(int, input().split()) t0 = [[-1 if c == "#" else 0 for c in input()] for _ in range(h)] for di in range(h): for dj in range(w): if (di, dj) == (0, 0): continue t = deepcopy(t0) br = False for i in range(h): for j in range(w): if t[i][j] != -1: continue if i + di >= h or j + dj >= w or t[i + di][j + dj] != -1: br = True break t[i][j] = 1 t[i + di][j + dj] = 2 if br: break if br: continue print("YES") exit() print("NO") main()