import java.util.*;
import java.io.*;
class Main {
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st= new StringTokenizer(br.readLine());
        int n = Integer.parseInt(st.nextToken());
        HashSet<String> hs = new HashSet();
        while(n--!=0){
            hs.add(br.readLine());
        }
        System.out.println(hs.size());
        

    }
}

//10 3 10 3 import java.util.*; util.* java import java.io.*; io.* java class Main {
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st= new StringTokenizer(br.readLine());
        int n = Integer.parseInt(st.nextToken());
        HashSet<String> hs = new HashSet();
        while(n--!=0){
            hs.add(br.readLine());
        }
        System.out.println(hs.size());
        

    }
} Main public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st= new StringTokenizer(br.readLine());
        int n = Integer.parseInt(st.nextToken());
        HashSet<String> hs = new HashSet();
        while(n--!=0){
            hs.add(br.readLine());
        }
        System.out.println(hs.size());
        

    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st= new StringTokenizer(br.readLine());
        int n = Integer.parseInt(st.nextToken());
        HashSet<String> hs = new HashSet();
        while(n--!=0){
            hs.add(br.readLine());
        }
        System.out.println(hs.size());
        

    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) StringTokenizer st= new StringTokenizer(br.readLine()); st new StringTokenizer(br.readLine()) int n = Integer.parseInt(st.nextToken()); n Integer.parseInt(st.nextToken()) Integer.parseInt Integer st.nextToken() st.nextToken st HashSet<String> hs = new HashSet(); hs new HashSet() while(n--!=0){
            hs.add(br.readLine());
        } n--!=0 n-- n 0 {
            hs.add(br.readLine());
        } hs.add(br.readLine()) hs.add hs br.readLine() br.readLine br System.out.println(hs.size()) System.out.println System.out System System.out hs.size() hs.size hs String[] args args
import java.util.*;
import java.io.*;
class Main {
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st= new StringTokenizer(br.readLine());
        int n = Integer.parseInt(st.nextToken());
        HashSet<String> hs = new HashSet();
        while(n--!=0){
            hs.add(br.readLine());
        }
        System.out.println(hs.size());
        

    }
}

//10 3 10 3