import java.util.*;
public class Main {
  public static void main(String[] args) {
    Scanner sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  }
} import java.util.*; util.* java public class Main {
  public static void main(String[] args) {
    Scanner sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  }
} Main public static void main(String[] args) {
    Scanner sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  } main {
    Scanner sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  } Scanner sc = new java.util.Scanner(System.in); sc new java.util.Scanner(System.in) int N = Integer.parseInt(sc.nextLine()); N Integer.parseInt(sc.nextLine()) Integer.parseInt Integer sc.nextLine() sc.nextLine sc String[] sNumbers = sc.nextLine().split(" "); sNumbers sc.nextLine().split(" ") sc.nextLine().split sc.nextLine() sc.nextLine sc " " Map<Integer, Integer> numbers = new HashMap<>(); numbers new HashMap<>() for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    } Integer i = 0; Integer i = 0; i 0 i < sNumbers.length i sNumbers.length sNumbers sNumbers.length i++ i++ i {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    } {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    } numbers.put(Integer.parseInt(sNumbers[i]), i) numbers.put numbers Integer.parseInt(sNumbers[i]) Integer.parseInt Integer sNumbers[i] sNumbers i i if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    } numbers.size() == N numbers.size() numbers.size numbers N {
      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 sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  }
} public class Main {
  public static void main(String[] args) {
    Scanner sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  }
} Main
import java.util.*;
public class Main {
  public static void main(String[] args) {
    Scanner sc = new java.util.Scanner(System.in);
    int N = Integer.parseInt(sc.nextLine());
    String[] sNumbers = sc.nextLine().split(" ");
    Map<Integer, Integer> numbers = new HashMap<>();
    for (Integer i = 0; i < sNumbers.length; i++) {
      numbers.put(Integer.parseInt(sNumbers[i]), i);
    }
    if (numbers.size() == N) {
      System.out.println("YES");
    } else {
      System.out.println("NO");
    }
  }
}
