        function Main(input) {
            var patternOne = "5 7 5";
            var patternTwo = "5 5 7";
            var patternThree = "7 5 5";
            input = input.split(" ");
            var fiveNum = 0;
            var sevenNum = 0;
            for (var i = 0; i < input.length; i++) {
                if (Number(input[i]) === 5) {
                    fiveNum++;
                } else if (Number(input[i]) === 7) {
                    sevenNum++;
                }
            }
            if (fiveNum === 2 && sevenNum === 1) {
                console.log("YES");
            } else {
                console.log("NO")
            }
        }
Main(require("fs").readFileSync("/dev/stdin", "utf8"));