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

class Solver {
	static final Solver INSTANCE = new Solver();

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

class Main {
	public static void main(String... args) {
		Scanner in = new Scanner(System.in);

		Solver.INSTANCE.solve(in);

		in.close();
	}
} import java.util.HashSet; HashSet java.util import java.util.Scanner; Scanner java.util import java.util.Set; Set java.util class Solver {
	static final Solver INSTANCE = new Solver();

	void solve(Scanner sc) {
		int N = sc.nextInt();
		Set<String > set  = new HashSet<>();
		for (int i = 0; i < N; i++) {
			set.add(sc.next());
		}
		System.out.println(set.size() == N ? "YES" : "NO");
	}
} Solver static final Solver INSTANCE = new Solver(); INSTANCE new Solver() void solve(Scanner sc) {
		int N = sc.nextInt();
		Set<String > set  = new HashSet<>();
		for (int i = 0; i < N; i++) {
			set.add(sc.next());
		}
		System.out.println(set.size() == N ? "YES" : "NO");
	} solve {
		int N = sc.nextInt();
		Set<String > set  = new HashSet<>();
		for (int i = 0; i < N; i++) {
			set.add(sc.next());
		}
		System.out.println(set.size() == N ? "YES" : "NO");
	} int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc Set<String > set  = new HashSet<>(); set new HashSet<>() for (int i = 0; i < N; i++) {
			set.add(sc.next());
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			set.add(sc.next());
		} {
			set.add(sc.next());
		} set.add(sc.next()) set.add set sc.next() sc.next 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" Scanner sc sc class Main {
	public static void main(String... args) {
		Scanner in = new Scanner(System.in);

		Solver.INSTANCE.solve(in);

		in.close();
	}
} Main public static void main(String... args) {
		Scanner in = new Scanner(System.in);

		Solver.INSTANCE.solve(in);

		in.close();
	} main {
		Scanner in = new Scanner(System.in);

		Solver.INSTANCE.solve(in);

		in.close();
	} Scanner in = new Scanner(System.in); in new Scanner(System.in) Solver.INSTANCE.solve(in) Solver.INSTANCE.solve Solver.INSTANCE Solver Solver.INSTANCE in in.close() in.close in String... args args
import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;

class Solver {
	static final Solver INSTANCE = new Solver();

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

class Main {
	public static void main(String... args) {
		Scanner in = new Scanner(System.in);

		Solver.INSTANCE.solve(in);

		in.close();
	}
}