import java.util.Scanner;

public class Main{
    public static void main(String[] args){
	Scanner scan = new Scanner(System.in);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    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);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    System.out.println("YES");
	}else{
	    System.out.println("NO");
	}
    }
} Main public static void main(String[] args){
	Scanner scan = new Scanner(System.in);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    System.out.println("YES");
	}else{
	    System.out.println("NO");
	}
    } main {
	Scanner scan = new Scanner(System.in);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    System.out.println("YES");
	}else{
	    System.out.println("NO");
	}
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int[] uta = new int[11]; uta new int[11] 11 int[] iroha = new int[3]; iroha new int[3] 3 for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	} int i = 0; int i = 0; i 0 i < 3 i 3 i++ i++ i {
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	} {
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	} iroha[i] = scan.nextInt() iroha[i] iroha i scan.nextInt() scan.nextInt scan uta[iroha[i]]++ uta[iroha[i]] uta iroha[i] iroha i if(uta[5] == 2 && uta[7] == 1){
	    System.out.println("YES");
	}else{
	    System.out.println("NO");
	} uta[5] == 2 && uta[7] == 1 uta[5] == 2 uta[5] uta 5 2 uta[7] == 1 uta[7] uta 7 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 scan = new Scanner(System.in);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    System.out.println("YES");
	}else{
	    System.out.println("NO");
	}
    }
} public class Main{
    public static void main(String[] args){
	Scanner scan = new Scanner(System.in);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    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);

	int[] uta = new int[11];
	int[] iroha = new int[3];
	for(int i = 0; i < 3; i++){
	    iroha[i] = scan.nextInt();
	    uta[iroha[i]]++;
	}

	if(uta[5] == 2 && uta[7] == 1){
	    System.out.println("YES");
	}else{
	    System.out.println("NO");
	}
    }
}
    
