S = input()
A,B,C = map(int,S.split())

if A==B and B==C:
  print("No")
elif A==B or A==C or B==C:
  print("Yes")
else:
  print("No") S = input() S input() input A,B,C = map(int,S.split()) A map(int,S.split()) map int S.split() S.split S split B C if A==B and B==C:
  print("No")
elif A==B or A==C or B==C:
  print("Yes")
else:
  print("No") A==B and B==C A==B A B B==C B C print("No") print "No" elif A==B or A==C or B==C:
  print("Yes") A==B or A==C or B==C A==B or A==C A==B A B A==C A C B==C B C print("Yes") print "Yes" print("No") print "No" B,C = map(int,S.split()) map(int,S.split()) B C = map(int,S.split()) map(int,S.split()) C A,B,C = map(int,S.split()) map(int,S.split()) A S = input() input() S
S = input()
A,B,C = map(int,S.split())

if A==B and B==C:
  print("No")
elif A==B or A==C or B==C:
  print("Yes")
else:
  print("No")