import java.io.FileNotFoundException;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) throws FileNotFoundException {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    }

} import java.io.FileNotFoundException; FileNotFoundException java.io import java.util.ArrayList; ArrayList java.util import java.util.HashSet; HashSet java.util import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) throws FileNotFoundException {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    }

} Main public static void main(String[] args) throws FileNotFoundException {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    } main {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc ArrayList<Integer> result = new ArrayList<>(); result new ArrayList<>() for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	} int i=0; int i=0; i 0 i<N i N i++ i++ i {
    		result.add(sc.nextInt());
    	} {
    		result.add(sc.nextInt());
    	} result.add(sc.nextInt()) result.add result sc.nextInt() sc.nextInt sc ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result)); ans new ArrayList<Integer>(new HashSet<>(result)) if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		} result.size()==ans.size() result.size() result.size result ans.size() ans.size ans {
			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 FileNotFoundException {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    }

} public class Main {
    public static void main(String[] args) throws FileNotFoundException {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    }

} Main
import java.io.FileNotFoundException;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) throws FileNotFoundException {

//    	File file = new File("src/in.txt");

        //コード
//    	Scanner sc = new Scanner(file);
    	Scanner sc = new Scanner(System.in);

    	int N = sc.nextInt();


    	ArrayList<Integer> result = new ArrayList<>();

    	for(int i=0;i<N;i++) {
    		result.add(sc.nextInt());
    	}
		ArrayList<Integer> ans = new ArrayList<Integer>(new HashSet<>(result));

		if(result.size()==ans.size()) {
			System.out.println("YES");
		} else {
			System.out.println("NO");
		}

    }

}