import sys

#探索
def DFS(mapmap):
    while 1:
        #はじめの探索
        start_flag = False
        for i in range(lines):
            for j in range(rows):
                if mapmap[i][j] == '#':
                    start_flag = True
                    break
        #則終了
        if start_flag == False:
            print('No')
            sys.exit()

        startl, startr = i, j
        #動き
        Stack = [[startl, startr]]

        move_x = [1, -1, 0, 0]
        move_y = [0, 0, 1, -1]

        while Stack:
            x, y= Stack.pop()#今現在の位置
            #現在位置を変換
            mapmap[x][y] = '.'

            for i in range(len(move_x)):
                nx = x + move_x[i]
                ny = y + move_y[i]

                if 0 <= nx and nx < lines and 0 <= ny and ny < rows:
                    if mapmap[nx][ny] == '#':
                        Stack.append([nx, ny])
        
        DFS(mapmap)

#入力管理
lines, rows = map(int, input().split())
mapmap = []

for i in range(lines):
    mapmap.append(list(input()))

DFS(mapmap)