N=int(input()) p=0 for i in range(N): s=input() p+=s.count('#') if N%2==0 and p%2==1: print('No') else: print('Yes')