#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>

#define BUF 12

int main(void) {
  long long int n;
  scanf("%lld", &n);
  char price_str[n][BUF];
  for (long long int i = 0; i < n; i++) {
    memset(price_str[i], '\0', BUF);
    char tmp[BUF];
    scanf(" %s", tmp);
    long long int pointer = 0;
    while (strnlen(price_str[pointer], BUF) && strncmp(tmp, price_str[pointer], BUF)) pointer++;
    if (!strnlen(price_str[pointer], BUF)) strncpy(price_str[pointer], tmp, BUF);
    // printf("%lld\n", pointer);
  }

  long long int result = 0;
  while (strnlen(price_str[result], BUF) && result < n) {
    // printf("%s\n", price_str[result]);
    result++;
  }

  printf("%lld\n", result);

  return 0;
}
