#include <iostream>
#include <string>
#include <utility>
#include <vector>
#include <set>
#include <stdio.h>
#include <stdlib.h>
using namespace std;
int main() 
{
	
	int number = 0;
	int i = 0;
	while(scanf("%d",&number) != EOF)
	{
		set<string> s;
		for(i=0;i<number;i++)
		{
			string str;
			cin >> str;
			s.insert(str);
		}
		cout << s.size()  << endl;
	}
	return 0;
}