import java.util.*;
public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	}
} import java.util.*; util.* java public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	}
} Main public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	} main {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = Integer.parseInt(sc.next()); N Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc String S[] = new String[N]; S new String[N] N Map<String, Integer> map = new HashMap<String, Integer>(); map new HashMap<String, Integer>() for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			S[i] = sc.next();
			map.put(S[i], 1);
		} {
			S[i] = sc.next();
			map.put(S[i], 1);
		} S[i] = sc.next() S[i] S i sc.next() sc.next sc map.put(S[i], 1) map.put map S[i] S i 1 System.out.println(map.size()) System.out.println System.out System System.out map.size() map.size map String args[] args public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	}
} public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	}
} Main
import java.util.*;
public class Main {
	public static void main(String args[]) {
		Scanner sc = new Scanner(System.in);
		int N = Integer.parseInt(sc.next());
		String S[] = new String[N];
		Map<String, Integer> map = new HashMap<String, Integer>();
		for(int i = 0; i < N; i++) {
			S[i] = sc.next();
			map.put(S[i], 1);
		}
		System.out.println(map.size());
	}
}
