import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		}


	}

} import java.util.ArrayList; ArrayList java.util import java.util.HashSet; HashSet java.util import java.util.List; List 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();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		}


	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		}


	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			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 List<Integer> list = new ArrayList<>(); list new ArrayList<>() for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			list.add(sc.nextInt());
		} {
			list.add(sc.nextInt());
		} list.add(sc.nextInt()) list.add list sc.nextInt() sc.nextInt sc sc.close() sc.close sc List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list)); list2 new ArrayList<Integer>(new HashSet<>(list)) if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		} list2.size() != n list2.size() list2.size list2 n {
			System.out.println("NO");
		} System.out.println("NO") System.out.println System.out System System.out "NO" {
			System.out.println("YES");
		} 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();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		}


	}

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		}


	}

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

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<Integer> list = new ArrayList<>();

		for(int i=0;i<n;i++) {
			list.add(sc.nextInt());
		}
		sc.close();

		List<Integer> list2 = new ArrayList<Integer>(new HashSet<>(list));


		if(list2.size() != n) {
			System.out.println("NO");
		}else {
			System.out.println("YES");
		}


	}

}