"use strict";

/**
 * @see https://practice.contest.atcoder.jp/tasks/practice_1
 * @param  {string} input
 * @returns {string}
 */
var main = function(input) {
    const items = input.split("\n").slice(1);
    let dictionary = {};
    items.forEach(x => dictionary[x] = 1);
    return Object.keys(dictionary).length;
};

const output = main(require("fs").readFileSync("/dev/stdin", "utf8"));
console.log(output); // console.log outputs with trailing new line!
