#include <bits/stdc++.h>
using namespace std;
map<pair<string, string>, bool> mp;
int main() {
  int n;
  cin >> n;
  int ans = 0;
  for (int i = 0; i < n; i++) {
    string a, b;
    cin >> a >> b;
    pair<string, string> pr;
    pr = make_pair(a, b);
    if (mp.count(pr) > 0) continue;
    mp[pr] = true;
    ans++;
  }
  cout << ans << endl;
  return 0;
}
