fun main(args: Array<String>) {
    val n = readLine()!!.split(" ").map { it.toInt() }[0]
    var keihinArray: Array<String> = Array(n){""}
    for (i in 0 until n){
        val s = readLine()!!.split(" ")[0]
        keihinArray[i] = s
    }
    val ansArray: Set<String> = keihinArray.toSet()
    val ans = ansArray.size
    println(ans)

}