_,a,_,b,_ = gets.split.map(&:to_i) puts a == b ? "Yes" : "No"