import java.util.HashSet;
import java.util.Scanner;

public class Main  {

    public static void main(String[] args) {

        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    }
} import java.util.HashSet; HashSet 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();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    }
} Main public static void main(String[] args) {

        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    } main {

        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc HashSet<Integer> hashSet = new HashSet<>(); hashSet new HashSet<>() while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        } n > 0 n 0 {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        } int val = sc.nextInt(); val sc.nextInt() sc.nextInt sc if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            } hashSet.contains( val) hashSet.contains hashSet val {
                System.out.println( "NO");
                return;
            } System.out.println( "NO") System.out.println System.out System System.out "NO" return; hashSet.add( val ) hashSet.add hashSet val n-- n 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 sc = new Scanner(System.in);
        int n = sc.nextInt();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    }
} public class Main  {

    public static void main(String[] args) {

        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    }
} Main
import java.util.HashSet;
import java.util.Scanner;

public class Main  {

    public static void main(String[] args) {

        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        HashSet<Integer> hashSet = new HashSet<>();
        while (n > 0 ) {
            int val = sc.nextInt();
            if(hashSet.contains( val)) {
                System.out.println( "NO");
                return;
            }
            hashSet.add( val );
             n--;
        }

            System.out.println("YES");

    }
}
