#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string x[300];
  for (int i = 0; i < 2 * n; i++) {
    cin >> x[i];
  }
  int num = 0;
  int c = 0;
  int j;
  for (int i = 0; i < 2 * n; i += 2) {
    num = 0;
    for (int j = i + 2; j < 2 * n; j += 2) {
      if (x[i] == x[j] && x[i + 1] == x[j + 1])
        continue;
      else
        num++;
    }
    if (2 * num == 2 * (n - i / 2 - 1)) c++;
  }
  cout << c;
}
