import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	}
} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	} main {
		Scanner scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) String A = scan.next(); A scan.next() scan.next scan String B = scan.next(); B scan.next() scan.next scan String C = scan.next(); C scan.next() scan.next scan if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        } A.equals("5") && B.equals("5") A.equals("5") A.equals A "5" B.equals("5") B.equals B "5" {
        	System.out.println("YES");
        } System.out.println("YES") System.out.println System.out System System.out "YES" if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        } B.equals("5") && C.equals("5") B.equals("5") B.equals B "5" C.equals("5") C.equals C "5" {
        	System.out.println("YES");
        } System.out.println("YES") System.out.println System.out System System.out "YES" if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        } A.equals("5") && C.equals("5") A.equals("5") A.equals A "5" C.equals("5") C.equals C "5" {
        	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 scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	}
} public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
        String A = scan.next();
        String B = scan.next();
        String C = scan.next();
        
        if(A.equals("5") && B.equals("5")) {
        	System.out.println("YES");
        }else if(B.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else if(A.equals("5") && C.equals("5")){
        	System.out.println("YES");
        }else {
        	System.out.println("NO");
        }
	}
}