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

class Main {
	public static void main(String[] args) throws Exception {
		new Main().run();
	}

	void run() {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		HashSet<Integer> set=new HashSet<>();
		for(int i=0;i<N;++i) {
			set.add(sc.nextInt());
		}
		System.out.println(set.size()==N?"YES":"NO");
	}

	static void tr(Object... objects) {
		System.out.println(Arrays.deepToString(objects));
	}

} import java.util.Arrays; Arrays java.util import java.util.HashSet; HashSet java.util import java.util.Scanner; Scanner java.util class Main {
	public static void main(String[] args) throws Exception {
		new Main().run();
	}

	void run() {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		HashSet<Integer> set=new HashSet<>();
		for(int i=0;i<N;++i) {
			set.add(sc.nextInt());
		}
		System.out.println(set.size()==N?"YES":"NO");
	}

	static void tr(Object... objects) {
		System.out.println(Arrays.deepToString(objects));
	}

} Main public static void main(String[] args) throws Exception {
		new Main().run();
	} main {
		new Main().run();
	} new Main().run() new Main().run new Main() String[] args args void run() {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		HashSet<Integer> set=new HashSet<>();
		for(int i=0;i<N;++i) {
			set.add(sc.nextInt());
		}
		System.out.println(set.size()==N?"YES":"NO");
	} run {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		HashSet<Integer> set=new HashSet<>();
		for(int i=0;i<N;++i) {
			set.add(sc.nextInt());
		}
		System.out.println(set.size()==N?"YES":"NO");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N=sc.nextInt(); N sc.nextInt() sc.nextInt sc HashSet<Integer> set=new HashSet<>(); set new HashSet<>() for(int i=0;i<N;++i) {
			set.add(sc.nextInt());
		} int i=0; int i=0; i 0 i<N i N ++i ++i i {
			set.add(sc.nextInt());
		} {
			set.add(sc.nextInt());
		} set.add(sc.nextInt()) set.add set sc.nextInt() sc.nextInt sc System.out.println(set.size()==N?"YES":"NO") System.out.println System.out System System.out set.size()==N?"YES":"NO" set.size()==N set.size() set.size set N "YES" "NO" static void tr(Object... objects) {
		System.out.println(Arrays.deepToString(objects));
	} tr {
		System.out.println(Arrays.deepToString(objects));
	} System.out.println(Arrays.deepToString(objects)) System.out.println System.out System System.out Arrays.deepToString(objects) Arrays.deepToString Arrays objects Object... objects objects
import java.util.Arrays;
import java.util.HashSet;
import java.util.Scanner;

class Main {
	public static void main(String[] args) throws Exception {
		new Main().run();
	}

	void run() {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		HashSet<Integer> set=new HashSet<>();
		for(int i=0;i<N;++i) {
			set.add(sc.nextInt());
		}
		System.out.println(set.size()==N?"YES":"NO");
	}

	static void tr(Object... objects) {
		System.out.println(Arrays.deepToString(objects));
	}

}
