while l = gets do
  c1,c2,c3 = l.split.map(&:to_i)
  cards = (1..10).to_a
  cards.delete(c1)
  cards.delete(c2)
  cards.delete(c3)
  rest = 20-(c1+c2)
  puts cards.select{|x| x>rest}.size > 3 ? "NO" : "YES"
end