a = map(int, input().split())
res = "No"
if len(set(a)) == 2:
  res = "Yes"
print(res) a = map(int, input().split()) a map(int, input().split()) map int input().split() ().split () input split res = "No" res "No" if len(set(a)) == 2:
  res = "Yes" len(set(a)) == 2 len(set(a)) len set(a) set a 2 res = "Yes" res "Yes" print(res) print res res = "Yes" "Yes" res res = "No" "No" res a = map(int, input().split()) map(int, input().split()) a
a = map(int, input().split())
res = "No"
if len(set(a)) == 2:
  res = "Yes"
print(res)