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

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

		// 入力値の取得
		int N = sc.nextInt();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	}
} import java.util.HashSet; HashSet 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();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		// 入力値の取得
		int N = sc.nextInt();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	} main {
		Scanner sc = new Scanner(System.in);

		// 入力値の取得
		int N = sc.nextInt();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc HashSet<Integer> A = new HashSet<>(); A new HashSet<>() for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		} {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		} if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			} !A.add(sc.nextInt()) A.add(sc.nextInt()) A.add A sc.nextInt() sc.nextInt sc {
				System.out.println("NO");
				return;
			} System.out.println("NO") System.out.println System.out System System.out "NO" return; System.out.println("YES") System.out.println System.out System System.out "YES" sc.close() sc.close sc String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		// 入力値の取得
		int N = sc.nextInt();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		// 入力値の取得
		int N = sc.nextInt();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	}
} Main
import java.util.HashSet;
import java.util.Scanner;

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

		// 入力値の取得
		int N = sc.nextInt();
		HashSet<Integer> A = new HashSet<>();
		
		// 結果の出力
		for (int i = 0; i < N; i++) {
			if (!A.add(sc.nextInt())) {
				System.out.println("NO");
				return;
			}
		}
		System.out.println("YES");
		
		sc.close();
	}
}
