
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

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

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    }

    static class Iroha {

    	public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	}
    }

} import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main
{
    public static void main( String[] args )
    {
		Scanner scanner = new Scanner (System.in);
		String input = scanner.nextLine();

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    }

    static class Iroha {

    	public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	}
    }

} Main public static void main( String[] args )
    {
		Scanner scanner = new Scanner (System.in);
		String input = scanner.nextLine();

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    } main {
		Scanner scanner = new Scanner (System.in);
		String input = scanner.nextLine();

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    } Scanner scanner = new Scanner (System.in); scanner new Scanner (System.in) String input = scanner.nextLine(); input scanner.nextLine() scanner.nextLine scanner Iroha solver = new Iroha(); solver new Iroha() System.out.println(solver.anotherSolve(input)) System.out.println System.out System System.out solver.anotherSolve(input) solver.anotherSolve solver input String[] args args static class Iroha {

    	public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	}
    } Iroha public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	} anotherSolve {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	} List<Integer> inputList = new ArrayList<Integer>(); inputList new ArrayList<Integer>() int five = 0; five 0 int seven = 0; seven 0 for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		} String s input.split(" ") input.split input " " {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		} {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		} if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			} Integer.parseInt(s)== 5 Integer.parseInt(s) Integer.parseInt Integer s 5 {
    				five++;
    			} five++ five if (Integer.parseInt(s)==7) {
    				seven++;
    			} Integer.parseInt(s)==7 Integer.parseInt(s) Integer.parseInt Integer s 7 {
    				seven++;
    			} seven++ seven if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		} five == 2 && seven == 1 five == 2 five 2 seven == 1 seven 1 {
    			return "YES";
    		} return "YES"; "YES" {
    			return "NO";
    		} return "NO"; "NO" String input input public class Main
{
    public static void main( String[] args )
    {
		Scanner scanner = new Scanner (System.in);
		String input = scanner.nextLine();

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    }

    static class Iroha {

    	public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	}
    }

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

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    }

    static class Iroha {

    	public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	}
    }

} Main

import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

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

		Iroha solver = new Iroha();

//		System.out.println(solver.solve(input));
		System.out.println(solver.anotherSolve(input));

    }

    static class Iroha {

    	public String anotherSolve(String input) {
    		List<Integer> inputList = new ArrayList<Integer>();
    		int five = 0;
    		int seven = 0;

    		for(String s:input.split(" ")) {
    			if(Integer.parseInt(s)== 5) {
    				five++;
    			} else if (Integer.parseInt(s)==7) {
    				seven++;
    			}
    		}
    		if (five == 2 && seven == 1) {
    			return "YES";
    		} else {
    			return "NO";
    		}
    	}
    }

}
