import java.util.Scanner;
import java.util.HashMap;

public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     }
} import java.util.Scanner; Scanner java.util import java.util.HashMap; HashMap java.util public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     }
} Main public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     } main {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc String[] B = new String[(int)(N)]; B new String[(int)(N)] (int)(N) for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        } int i = 0 ; int i = 0 ; i 0 i < N i N i++ i++ i {
                B[i] = sc.next();
                
        } {
                B[i] = sc.next();
                
        } B[i] = sc.next() B[i] B i sc.next() sc.next sc HashMap<String, Integer> m = new HashMap<String, Integer>(); m new HashMap<String, Integer>() int a = 0; a 0 for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        } String s B {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        } {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        } int v = 0; v 0 if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        } m.containsKey(s) m.containsKey m s {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } v = m.get(s) + 1 v m.get(s) + 1 m.get(s) m.get m s 1 a++ a {
        // Mapに未登録
        v = 1;
        } v = 1 v 1 m.put(s, v) m.put m s v System.out.println(N - a) System.out.println System.out System System.out N - a N a String[] args args public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     }
} public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     }
} Main
import java.util.Scanner;
import java.util.HashMap;

public class Main {
    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        
        int N = sc.nextInt();
        String[] B = new String[(int)(N)];
        
        for(int i = 0 ; i < N ; i++){
                B[i] = sc.next();
                
        }
        HashMap<String, Integer> m = new HashMap<String, Integer>();
        int a = 0;
        for (String s : B) {
        int v = 0;
        if (m.containsKey(s)) {
        // Mapに登録済み
        v = m.get(s) + 1;
        a++;
        } else {
        // Mapに未登録
        v = 1;
        }
        m.put(s, v);
        }
        
        System.out.println(N - a);
     }
}