#include<bits/stdc++.h>
using namespace std;

int main()
{

    set<string> Help;
    string str;
    while( cin>>str )
    {
        Help.insert(str);
    }

    int sum=0;
    for( auto temp : Help )
    {
        ++sum;
    }
    cout<<sum<<endl;
    return 0;
}