import java.util.*;

public class Main {

        public static void main(String[] args) {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        }
} import java.util.*; util.* java public class Main {

        public static void main(String[] args) {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        }
} Main public static void main(String[] args) {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        } main {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                } Exception e {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                } System.out.println("入力値が不正です") System.out.println System.out System System.out "入力値が不正です" {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } int c5 = 0; c5 0 int c7 = 0; c7 0 for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        } int i = 0; int i = 0; i 0 i<3 i 3 i++ i++ i {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        } {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        } int input = sc.nextInt(); input sc.nextInt() sc.nextInt sc if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                } input == 5 input 5 {
                                        c5++;
                                } c5++ c5 if (input ==7) {
                                        c7++;
                                } input ==7 input 7 {
                                        c7++;
                                } c7++ c7 if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        } c5 == 2 && c7 == 1 c5 == 2 c5 2 c7 == 1 c7 1 {
                                System.out.println("YES");
                        } System.out.println("YES") System.out.println System.out System System.out "YES" {
                                System.out.println("NO");
                        } System.out.println("NO") System.out.println System.out System System.out "NO" String[] args args public class Main {

        public static void main(String[] args) {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        }
} public class Main {

        public static void main(String[] args) {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        }
} Main
import java.util.*;

public class Main {

        public static void main(String[] args) {
                Scanner sc = new Scanner(System.in);
                try {
                        int c5 = 0;
                        int c7 = 0;
                        for (int i = 0; i<3; i++ ) {
                                int input = sc.nextInt();
                                if (input == 5) {
                                        c5++;
                                } else if (input ==7) {
                                        c7++;
                                }
                        }
                        if (c5 == 2 && c7 == 1) {
                                System.out.println("YES");
                        } else {
                                System.out.println("NO");
                        }

                } catch (Exception e) {
                //      e.printStackTrace();
                        System.out.println("入力値が不正です");
                }
        }
}