n = int(input()) C = set() for i in range(n): a, b = map(int, input().split()) c = a * 100000 + b if c in C: print("Yes") exit() C.add(c) print("No")