import java.util.*;

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

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    } main {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc String answer = "YES"; answer "YES" Set<Integer> map = new HashSet<>(); map new HashSet<>() for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        } {
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        } int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc if(map.contains(a)){
                answer = "NO";
                break;
            } map.contains(a) map.contains map a {
                answer = "NO";
                break;
            } answer = "NO" answer "NO" break; map.add(a) map.add map a System.out.println(answer) System.out.println System.out System System.out answer String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    }
} Main
import java.util.*;

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

        String answer = "YES";

        Set<Integer> map = new HashSet<>();
        for(int i = 0; i < N; i++){
            int a = sc.nextInt();
            if(map.contains(a)){
                answer = "NO";
                break;
            }
            map.add(a);
        }
        System.out.println(answer);
    }
}