ary = gets.split(" ").map{|v| v.to_s}

A = ary[0]
B = ary[1]
C = ary[2]

if A < B then
  if C < A then
    puts "No"
  elsif B < C then
    puts "No"
  else
    puts "Yes"
  end
else
  # B < A
  if C < B then
    puts "No"
  elsif A < C then
    puts "No"
  else
    puts "Yes"
  end
end