#include <bits/stdc++.h>
using namespace std;
vector<int> v, v1, v2;
int main() {
  int n, ans = 0;
  cin >> n;
  vector<pair<string, string> > p(n);
  for (int i = 0; i < n; i++) {
    cin >> p[i].first >> p[i].second;
  }
  sort(p.begin(), p.end());
  for (int i = 0; i < n; i++) {
    if (p[i].first == p[i + 1].first && p[i].second != p[i + 1].second) {
      ans++;
    } else if (p[i].first != p[i + 1].first) {
      ans++;
    }
  }
  cout << ans << endl;
  return 0;
}
