'use strict'
function Main(input) {
  const arr = input.split(" ");
  let count5 = 0, count7 = 0;
  
  arr.map(a => {
    if(a == 5){
      count5++;
    }else if(a == 7){
      count7++;
    }
  });
 
  console.log(count5 === 2 && count7 === 1 ? 'YES' : 'NO');
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));