import java.util.Scanner;

public class Main {

    private static int fiveCount = 0;
    private static int sevenCount = 0;

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    }

    static void check(int target) {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    }


} import java.util.Scanner; Scanner java.util public class Main {

    private static int fiveCount = 0;
    private static int sevenCount = 0;

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    }

    static void check(int target) {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    }


} Main private static int fiveCount = 0; fiveCount 0 private static int sevenCount = 0; sevenCount 0 public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    } main {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int A = Integer.parseInt(scanner.next()); A Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner int B = Integer.parseInt(scanner.next()); B Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner int C = Integer.parseInt(scanner.next()); C Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner scanner.close() scanner.close scanner check(A) check A check(B) check B check(C) check C boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1; isFiveSevenFive fiveCount == 2 && sevenCount == 1 fiveCount == 2 fiveCount 2 sevenCount == 1 sevenCount 1 System.out.println(isFiveSevenFive ? "YES" : "NO") System.out.println System.out System System.out isFiveSevenFive ? "YES" : "NO" isFiveSevenFive "YES" "NO" String[] args args static void check(int target) {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    } check {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    } if (target == 5) {
            fiveCount++;
        } target == 5 target 5 {
            fiveCount++;
        } fiveCount++ fiveCount if (target == 7) {
            sevenCount++;
        } target == 7 target 7 {
            sevenCount++;
        } sevenCount++ sevenCount int target target public class Main {

    private static int fiveCount = 0;
    private static int sevenCount = 0;

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    }

    static void check(int target) {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    }


} public class Main {

    private static int fiveCount = 0;
    private static int sevenCount = 0;

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    }

    static void check(int target) {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    }


} Main
import java.util.Scanner;

public class Main {

    private static int fiveCount = 0;
    private static int sevenCount = 0;

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int A = Integer.parseInt(scanner.next());
        int B = Integer.parseInt(scanner.next());
        int C = Integer.parseInt(scanner.next());
        scanner.close();

        check(A);
        check(B);
        check(C);

        boolean isFiveSevenFive = fiveCount == 2 && sevenCount == 1;

        System.out.println(isFiveSevenFive ? "YES" : "NO");
    }

    static void check(int target) {
        if (target == 5) {
            fiveCount++;
        }
        if (target == 7) {
            sevenCount++;
        }
    }


}
