import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        Map<String,Integer> map = new HashMap<>();
        int ans = 0;
        for(int i = 0;i < n;i++){
            String s = sc.next();
            map.put(s,1);
        }

        Iterator ite = map.values().iterator();
        while(ite.hasNext()){
            ans += (Integer)ite.next();
        }
        System.out.println(ans);
    }
} import java.util.*; util.* java class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        Map<String,Integer> map = new HashMap<>();
        int ans = 0;
        for(int i = 0;i < n;i++){
            String s = sc.next();
            map.put(s,1);
        }

        Iterator ite = map.values().iterator();
        while(ite.hasNext()){
            ans += (Integer)ite.next();
        }
        System.out.println(ans);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        Map<String,Integer> map = new HashMap<>();
        int ans = 0;
        for(int i = 0;i < n;i++){
            String s = sc.next();
            map.put(s,1);
        }

        Iterator ite = map.values().iterator();
        while(ite.hasNext()){
            ans += (Integer)ite.next();
        }
        System.out.println(ans);
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        Map<String,Integer> map = new HashMap<>();
        int ans = 0;
        for(int i = 0;i < n;i++){
            String s = sc.next();
            map.put(s,1);
        }

        Iterator ite = map.values().iterator();
        while(ite.hasNext()){
            ans += (Integer)ite.next();
        }
        System.out.println(ans);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc Map<String,Integer> map = new HashMap<>(); map new HashMap<>() int ans = 0; ans 0 for(int i = 0;i < n;i++){
            String s = sc.next();
            map.put(s,1);
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            String s = sc.next();
            map.put(s,1);
        } {
            String s = sc.next();
            map.put(s,1);
        } String s = sc.next(); s sc.next() sc.next sc map.put(s,1) map.put map s 1 Iterator ite = map.values().iterator(); ite map.values().iterator() map.values().iterator map.values() map.values map while(ite.hasNext()){
            ans += (Integer)ite.next();
        } ite.hasNext() ite.hasNext ite {
            ans += (Integer)ite.next();
        } ans += (Integer)ite.next() ans (Integer)ite.next() ite.next ite System.out.println(ans) System.out.println System.out System System.out ans String[] args args
import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        Map<String,Integer> map = new HashMap<>();
        int ans = 0;
        for(int i = 0;i < n;i++){
            String s = sc.next();
            map.put(s,1);
        }

        Iterator ite = map.values().iterator();
        while(ite.hasNext()){
            ans += (Integer)ite.next();
        }
        System.out.println(ans);
    }
}