import           Control.Monad.State
import qualified Data.ByteString.Char8        as B
import qualified Data.Vector.Unboxed          as U
import qualified Data.Hashable                as H
import qualified Data.IntSet                  as S

type Parser a = StateT B.ByteString Maybe a

parseInt :: Parser Int
parseInt = StateT $ B.readInt . B.dropWhile ((==) ' ')

readParser :: Parser a -> IO a
readParser p = maybe (error "parser error") fst . runStateT p <$> B.getLine

main :: IO ()
main = do
  n  <- readParser parseInt
  ss <- U.replicateM n $ H.hash <$> B.getLine
  print $ solve ss

solve :: U.Vector Int -> Int
solve = S.size . U.foldr S.insert S.empty
