x = list(map(int, input().split()))

if len(set(x))==2:
    kotae='Yes'
else:
    kotae='No'

print(kotae) x = list(map(int, input().split())) x list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split if len(set(x))==2:
    kotae='Yes'
else:
    kotae='No' len(set(x))==2 len(set(x)) len set(x) set x 2 kotae='Yes' kotae 'Yes' kotae='No' kotae 'No' print(kotae) print kotae kotae='Yes' 'Yes' kotae x = list(map(int, input().split())) list(map(int, input().split())) x kotae='No' 'No' kotae
x = list(map(int, input().split()))

if len(set(x))==2:
    kotae='Yes'
else:
    kotae='No'

print(kotae)