import java.util.Scanner;

public class Main {

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

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

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

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

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

} public class Main {

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

} Main
import java.util.Scanner;

public class Main {

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

}
