import org.w3c.dom.ls.LSOutput;

import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    }
} import org.w3c.dom.ls.LSOutput; LSOutput org.w3c.dom.ls import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    }
} Main public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    } main {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int N = scanner.nextInt(); N scanner.nextInt() scanner.nextInt scanner long[] values = new long[N]; values new long[N] N for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            values[i] = scanner.nextLong();
        } {
            values[i] = scanner.nextLong();
        } values[i] = scanner.nextLong() values[i] values i scanner.nextLong() scanner.nextLong scanner Arrays.sort(values) Arrays.sort Arrays values for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        } int i = 0; int i = 0; i 0 i < values.length - 1 i values.length - 1 values.length values values.length 1 i++ i++ i {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        } {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        } if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            } values[i] == values[i + 1] values[i] values i values[i + 1] values i + 1 i 1 {
                System.out.println("NO");
                return;
            } System.out.println("NO") System.out.println System.out System System.out "NO" return; System.out.println("YES") System.out.println System.out System System.out "YES" String[] args args public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    }
} public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    }
} Main
import org.w3c.dom.ls.LSOutput;

import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        long[] values = new long[N];
        for(int i = 0; i < N; i++) {
            values[i] = scanner.nextLong();
        }
        Arrays.sort(values);
        for(int i = 0; i < values.length - 1; i++) {
            if(values[i] == values[i + 1]) {
                System.out.println("NO");
                return;
            }
        }
        System.out.println("YES");
    }
}
