import java.util.Scanner;
import java.util.HashSet;
public class Main{
    public static void main(String[]args){
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    }
} import java.util.Scanner; Scanner java.util import java.util.HashSet; HashSet java.util public class Main{
    public static void main(String[]args){
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    }
} Main public static void main(String[]args){
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    } main {
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n n flag; flag flag=0 flag 0 n= scan.nextInt() n scan.nextInt() scan.nextInt scan HashSet<String>hs = new HashSet<String>(); hs new HashSet<String>() for(int i=0;i<n;i++){
            hs.add(scan.next());
        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            hs.add(scan.next());
        } {
            hs.add(scan.next());
        } hs.add(scan.next()) hs.add hs scan.next() scan.next scan if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO"); n==hs.size() n hs.size() hs.size hs System.out.printf("YES") System.out.printf System.out System System.out "YES" System.out.printf("NO") System.out.printf System.out System System.out "NO" String[]args args public class Main{
    public static void main(String[]args){
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    }
} public class Main{
    public static void main(String[]args){
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    }
} Main
import java.util.Scanner;
import java.util.HashSet;
public class Main{
    public static void main(String[]args){
        Scanner scan = new Scanner(System.in);
        int n,flag;
        flag=0;
        n= scan.nextInt();
        HashSet<String>hs = new HashSet<String>();
        for(int i=0;i<n;i++){
            hs.add(scan.next());
        }
        if(n==hs.size()) System.out.printf("YES");
        else System.out.printf("NO");
    }
}