import java.util.*;
class Main{
	public static void main(String args[]){
      Scanner sc = new Scanner(System.in);
      int a = sc.nextInt();
      Set t = new HashSet<Integer>();
      boolean ok = true;
      for(int i = 0;i<a;i++){
        t.add(sc.nextInt());
      }

      if(t.size()==a)System.out.println("YES");
      else System.out.println("NO");
    }
} import java.util.*; util.* java class Main{
	public static void main(String args[]){
      Scanner sc = new Scanner(System.in);
      int a = sc.nextInt();
      Set t = new HashSet<Integer>();
      boolean ok = true;
      for(int i = 0;i<a;i++){
        t.add(sc.nextInt());
      }

      if(t.size()==a)System.out.println("YES");
      else System.out.println("NO");
    }
} Main public static void main(String args[]){
      Scanner sc = new Scanner(System.in);
      int a = sc.nextInt();
      Set t = new HashSet<Integer>();
      boolean ok = true;
      for(int i = 0;i<a;i++){
        t.add(sc.nextInt());
      }

      if(t.size()==a)System.out.println("YES");
      else System.out.println("NO");
    } main {
      Scanner sc = new Scanner(System.in);
      int a = sc.nextInt();
      Set t = new HashSet<Integer>();
      boolean ok = true;
      for(int i = 0;i<a;i++){
        t.add(sc.nextInt());
      }

      if(t.size()==a)System.out.println("YES");
      else System.out.println("NO");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc Set t = new HashSet<Integer>(); t new HashSet<Integer>() boolean ok = true; ok true for(int i = 0;i<a;i++){
        t.add(sc.nextInt());
      } int i = 0; int i = 0; i 0 i<a i a i++ i++ i {
        t.add(sc.nextInt());
      } {
        t.add(sc.nextInt());
      } t.add(sc.nextInt()) t.add t sc.nextInt() sc.nextInt sc if(t.size()==a)System.out.println("YES");
      else System.out.println("NO"); t.size()==a t.size() t.size t a System.out.println("YES") System.out.println System.out System System.out "YES" System.out.println("NO") System.out.println System.out System System.out "NO" String args[] args
import java.util.*;
class Main{
	public static void main(String args[]){
      Scanner sc = new Scanner(System.in);
      int a = sc.nextInt();
      Set t = new HashSet<Integer>();
      boolean ok = true;
      for(int i = 0;i<a;i++){
        t.add(sc.nextInt());
      }

      if(t.size()==a)System.out.println("YES");
      else System.out.println("NO");
    }
}