if __name__ == '__main__':
	
	A = set(map(int,input().split()))
	if len(A) == 2:
		print("Yes")
	else:
		print("No")
 if __name__ == '__main__':
	
	A = set(map(int,input().split()))
	if len(A) == 2:
		print("Yes")
	else:
		print("No") __name__ == '__main__' __name__ '__main__' A = set(map(int,input().split())) A set(map(int,input().split())) set map(int,input().split()) map int input().split() ().split () input split if len(A) == 2:
		print("Yes")
	else:
		print("No") len(A) == 2 len(A) len A 2 print("Yes") print "Yes" print("No") print "No" A = set(map(int,input().split())) set(map(int,input().split())) A
if __name__ == '__main__':
	
	A = set(map(int,input().split()))
	if len(A) == 2:
		print("Yes")
	else:
		print("No")

