N = int(input()) P = [input() for _ in range(N)] ans = [P[0]] for i in range(1, N): if P[i] == "Yes": ans.append(ans[-1]) else: if ans[-1] == "Yes": ans.append("No") else: ans.append("Yes") for a in ans: print(a)