x,y,z = map(int, input().split())

if x == y == z:
  print("No")
elif x == y or y ==z or z ==x:
  print("Yes")
else:
  print("No") x,y,z = map(int, input().split()) x map(int, input().split()) map int input().split() ().split () input split y z if x == y == z:
  print("No")
elif x == y or y ==z or z ==x:
  print("Yes")
else:
  print("No") x == y == z x == y x y z print("No") print "No" elif x == y or y ==z or z ==x:
  print("Yes") x == y or y ==z or z ==x x == y or y ==z x == y x y y ==z y z z ==x z x print("Yes") print "Yes" print("No") print "No" y,z = map(int, input().split()) map(int, input().split()) y x,y,z = map(int, input().split()) map(int, input().split()) x z = map(int, input().split()) map(int, input().split()) z
x,y,z = map(int, input().split())

if x == y == z:
  print("No")
elif x == y or y ==z or z ==x:
  print("Yes")
else:
  print("No")