import java.util.*;

public class Main {
    public static void main(String[] args) {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

        if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        }
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

        if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        }
    }
} Main public static void main(String[] args) {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

        if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        }
    } main {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

        if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        }
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) Integer N = Integer.parseInt(scanner.next()); N Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner TreeSet<Integer> ts = new TreeSet<>(); ts new TreeSet<>() for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next())); int i = 0; int i = 0; i 0 i < N i N i++ i++ i ts.add(Integer.parseInt(scanner.next())); ts.add(Integer.parseInt(scanner.next())) ts.add ts Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        } N == ts.size() N ts.size() ts.size ts {
            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) {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

        if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        }
    }
} public class Main {
    public static void main(String[] args) {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

        if(N == ts.size()) {
            System.out.println("YES");
        } else {
            System.out.println("NO");
        }
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) {
        //コード
        Scanner scanner = new Scanner(System.in);
        Integer N = Integer.parseInt(scanner.next());
        TreeSet<Integer> ts = new TreeSet<>();

        for (int i = 0; i < N; i++) ts.add(Integer.parseInt(scanner.next()));

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