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

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    }
} import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int[] array = new int[n]; array new int[n] n boolean b = true; b true int i; i for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        } i=0; i=0 i 0 i<n i n i++ i++ i {
            array[i] = sc.nextInt();
        } {
            array[i] = sc.nextInt();
        } array[i] = sc.nextInt() array[i] array i sc.nextInt() sc.nextInt sc Arrays.sort(array) Arrays.sort Arrays array for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        } i=0; i=0 i 0 i<n i n i++ i++ i {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        } {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        } if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            } i != 0 i 0 {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            } if (array[i-1] == array[i]) {
                    b = false;
                    break;
                } array[i-1] == array[i] array[i-1] array i-1 i 1 array[i] array i {
                    b = false;
                    break;
                } b = false b false break; System.out.println(b ? "YES" : "NO") System.out.println System.out System System.out b ? "YES" : "NO" b "YES" "NO" String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    }
} Main
import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] array = new int[n];
        boolean b = true;
        int i;
        for (i=0; i<n; i++) {
            array[i] = sc.nextInt();
        }
        Arrays.sort(array);
        for (i=0; i<n; i++) {
            if (i != 0) {
                if (array[i-1] == array[i]) {
                    b = false;
                    break;
                }
            }
        }
        System.out.println(b ? "YES" : "NO");
    }
}