import java.util.*;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  }
} import java.util.*; util.* java public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  }
} Main public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  } main {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int go = 0; go 0 int seven = 0; seven 0 int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc if(a == 5) go++; a == 5 a 5 go++ go if(a == 7) seven++; a == 7 a 7 seven++ seven int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc if(b == 5) go++; b == 5 b 5 go++ go if(b == 7) seven++; b == 7 b 7 seven++ seven int c = sc.nextInt(); c sc.nextInt() sc.nextInt sc if(c == 5) go++; c == 5 c 5 go++ go if(c == 7) seven++; c == 7 c 7 seven++ seven String ans = "NO"; ans "NO" if((go == 2) && (seven == 1)) ans = "YES"; (go == 2) && (seven == 1) (go == 2) go 2 (seven == 1) seven 1 ans = "YES" ans "YES" System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  }
} public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  }
} Main
import java.util.*;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    int go = 0;
    int seven = 0;
    int a = sc.nextInt();
    if(a == 5) go++;
    if(a == 7) seven++;
    int b = sc.nextInt();
    if(b == 5) go++;
    if(b == 7) seven++;
    int c = sc.nextInt();
    if(c == 5) go++;
    if(c == 7) seven++;
    String ans = "NO";
    if((go == 2) && (seven == 1)) ans = "YES";
    System.out.println(ans);
  }
}