import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    }
} import java.util.*; util.* java public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    }
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    } main {
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc boolean ans = true; ans true List<String> list = new ArrayList<String>(); list new ArrayList<String>() for(int i = 0;i < n;i++){
          list.add(sc.next());
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
          list.add(sc.next());
        } {
          list.add(sc.next());
        } list.add(sc.next()) list.add list sc.next() sc.next sc ans = (list.size() == new HashSet<>(list).size()) ans (list.size() == new HashSet<>(list).size()) list.size() list.size list new HashSet<>(list).size() new HashSet<>(list).size new HashSet<>(list) if(ans == false){
          System.out.println("NO");
          return;
          } ans == false ans false {
          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" String[] args args public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    }
} public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    }
} Main
import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		// 整数の入力
		int n = sc.nextInt();
        boolean ans = true;
        List<String> list = new ArrayList<String>();
        for(int i = 0;i < n;i++){
          list.add(sc.next());
        }
        
        

        ans = (list.size() == new HashSet<>(list).size());
        if(ans == false){
          System.out.println("NO");
          return;
          }
        System.out.println("YES");
    }
}