import Data.List (group, sort)

main :: IO ()
main = tail <$> readInts >>= print . solve

readInts :: IO [Int]
readInts = map read . words <$> getContents

solve :: [Int] ->  Int
solve = length . group . sort
