import java.util.*;

public class Main{
    public static void main(String[] args){
        Scanner scan = new java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            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 java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
} Main public static void main(String[] args){
        Scanner scan = new java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    } main {
        Scanner scan = new java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    } Scanner scan = new java.util.Scanner(System.in); scan new java.util.Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan int[] a = new int[n]; a new int[n] n boolean b = false; b false for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            a[i] = scan.nextInt();
        } {
            a[i] = scan.nextInt();
        } a[i] = scan.nextInt() a[i] a i scan.nextInt() scan.nextInt scan Arrays.sort(a) Arrays.sort Arrays a for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        } int i = 0; int i = 0; i 0 i < n - 1 i n - 1 n 1 i++ i++ i {
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        } {
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        } if(a[i] == a[i + 1]){
                b = true;
                break;
            } a[i] == a[i + 1] a[i] a i a[i + 1] a i + 1 i 1 {
                b = true;
                break;
            } b = true b true break; if(!b){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        } !b b {
            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 java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
} public class Main{
    public static void main(String[] args){
        Scanner scan = new java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            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 java.util.Scanner(System.in);
        int n = scan.nextInt();
        int[] a = new int[n];
        boolean b = false;
        for(int i = 0; i < n; i++){
            a[i] = scan.nextInt();
        }
        Arrays.sort(a);
        for(int i = 0; i < n - 1; i++){
            if(a[i] == a[i + 1]){
                b = true;
                break;
            }
        }
        if(!b){
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
}