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