n = int(input()) ans = "No" for _ in range(n): if input().endswith(" 1"): ans = "Yes" print(ans)