import java.util.*;

public class Main {
  public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  }
} import java.util.*; util.* java public class Main {
  public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  }
} Main public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  } main {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int count1 = 0; count1 0 int count2 = 0; count2 0 for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    } int i = 0; int i = 0; i 0 i < 3 i 3 i++ i++ i {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    } {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    } int token1 = sc.nextInt(); token1 sc.nextInt() sc.nextInt sc if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      } token1 == 7 && count1 <= 1 token1 == 7 token1 7 count1 <= 1 count1 1 {
          count1++;
      } count1++ count1 if(token1 == 5 && count1 <= 2) {
          count2++;
      } token1 == 5 && count1 <= 2 token1 == 5 token1 5 count1 <= 2 count1 2 {
          count2++;
      } count2++ count2 if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    } count1 == 1 && count2 == 2 count1 == 1 count1 1 count2 == 2 count2 2 {
        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 ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  }
} public class Main {
  public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  }
} Main
import java.util.*;

public class Main {
  public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int count1 = 0;
    int count2 = 0;
    
    for (int i = 0; i < 3; i++) {
      int token1 = sc.nextInt();
      
      if(token1 == 7 && count1 <= 1) {
          count1++;
      }else if(token1 == 5 && count1 <= 2) {
          count2++;
      }
    }
    
    if(count1 == 1 && count2 == 2) {
        System.out.println("YES");
    }else {
        System.out.println("NO");
    }
  }
}
