import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n =sc.nextInt();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n =sc.nextInt();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n =sc.nextInt();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	} main {
		Scanner sc = new Scanner(System.in);
		int n =sc.nextInt();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n =sc.nextInt(); n sc.nextInt() sc.nextInt sc Set<Integer> ch = new HashSet<>(); ch new HashSet<>() for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			int d=sc.nextInt();
			ch.add(d);
		} {
			int d=sc.nextInt();
			ch.add(d);
		} int d=sc.nextInt(); d sc.nextInt() sc.nextInt sc ch.add(d) ch.add ch d if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		} n==ch.size() n ch.size() ch.size ch {
			System.out.println("YES");
		} System.out.println("YES") System.out.println System.out System System.out "YES" {
			System.out.println("NO");
		} System.out.println("NO") System.out.println System.out System System.out "NO" 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();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n =sc.nextInt();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	}
} Main
import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n =sc.nextInt();
		Set<Integer> ch = new HashSet<>();
		
		for(int i=0;i<n;i++) {
			int d=sc.nextInt();
			ch.add(d);
		}

		if(n==ch.size()) {
			System.out.println("YES");
		}else {
			System.out.println("NO");
		}
		
		sc.close();
	}
}