n = int(input()) g = [input() for i in range(n)] x = sum(i.count('#') for i in g) if x%2==1 and n%2==0: print("No") else: print("Yes")