import java.util.Scanner;

public class Main {
	static int five,seven;
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	}
	public static void check(int N) {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	static int five,seven;
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	}
	public static void check(int N) {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	}
} Main static int five five seven; seven public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	} main {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int A = scanner.nextInt(); A scanner.nextInt() scanner.nextInt scanner int B = scanner.nextInt(); B scanner.nextInt() scanner.nextInt scanner int C = scanner.nextInt(); C scanner.nextInt() scanner.nextInt scanner five=0 five 0 seven=0 seven 0 check(A) check A check(B) check B check(C) check C if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO"); five==2&&seven==1 five==2 five 2 seven==1 seven 1 System.out.println("YES") System.out.println System.out System System.out "YES" System.out.println("NO") System.out.println System.out System System.out "NO" scanner.close() scanner.close scanner String[] args args public static void check(int N) {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	} check {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	} if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		} N==5 N 5 {
			five++;
		} five++ five if(N==7) {
			seven++;
		} N==7 N 7 {
			seven++;
		} seven++ seven int N N public class Main {
	static int five,seven;
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	}
	public static void check(int N) {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	}
} public class Main {
	static int five,seven;
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	}
	public static void check(int N) {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	}
} Main
import java.util.Scanner;

public class Main {
	static int five,seven;
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		int A = scanner.nextInt();
		int B = scanner.nextInt();
		int C = scanner.nextInt();
		five=0;
		seven=0;

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

		if(five==2&&seven==1) System.out.println("YES");
		else System.out.println("NO");
		scanner.close();
	}
	public static void check(int N) {
		if(N==5) {
			five++;
		}
		else if(N==7) {
			seven++;
		}
	}
}
