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

public class Main {
	public static void main(String[] args){
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	}
} import java.util.HashSet; HashSet java.util import java.util.Scanner; Scanner java.util import java.util.Set; Set java.util public class Main {
	public static void main(String[] args){
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	}
} Main public static void main(String[] args){
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	} main {
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	} try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		} {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		} Scanner sc = new Scanner(System.in) Scanner sc = new Scanner(System.in) new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc Set<Integer> countSet = new HashSet<>(); countSet new HashSet<>() boolean isDuplicated = false; isDuplicated false for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			} int i = 0 ; int i = 0 ; i 0 i < n i n i++ i++ i {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			} {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			} int v = sc.nextInt(); v sc.nextInt() sc.nextInt sc if (countSet.contains(v)) {
					isDuplicated = true;
				} countSet.contains(v) countSet.contains countSet v {
					isDuplicated = true;
				} isDuplicated = true isDuplicated true countSet.add(v) countSet.add countSet v if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			} isDuplicated {
				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){
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	}
} public class Main {
	public static void main(String[] args){
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	}
} Main
import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;

public class Main {
	public static void main(String[] args){
		try(Scanner sc = new Scanner(System.in)) {
		
			int n = sc.nextInt();
			
			Set<Integer> countSet = new HashSet<>();
			boolean isDuplicated = false;
			
			for(int i = 0 ; i < n ; i++ ) {
				
				int v = sc.nextInt();
				
				if (countSet.contains(v)) {
					isDuplicated = true;
				}
				countSet.add(v);
			}
			
			if ( isDuplicated ) {
				System.out.println("NO");
			}
			else {
				System.out.println("YES");
			}
		}
	}
}