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