import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
} Main public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    } main {
        Scanner scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan ArrayList<Integer> a = new ArrayList<>(); a new ArrayList<>() for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            a.add(scan.nextInt());
        } {
            a.add(scan.nextInt());
        } a.add(scan.nextInt()) a.add a scan.nextInt() scan.nextInt scan ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a)); aa new ArrayList<>(new HashSet<>(a)) if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        } aa.size() == n aa.size() aa.size aa n {
            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 scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
} public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int n = scan.nextInt();
        ArrayList<Integer> a = new ArrayList<>();
        for(int i = 0; i < n; i++){
            a.add(scan.nextInt());
        }
        ArrayList<Integer> aa = new ArrayList<>(new HashSet<>(a));
        if(aa.size() == n){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
}