module M = Map.Make (struct type t = int let compare = (-) end) let read () = Scanf.scanf "%d " (fun i -> i) let () = let n = read () in let rec doit i m = if i = n then m else let a = read () in doit (i + 1) (if not (M.mem a m) then M.add a 1 m else M.add a (M.find a m + 1) m) in let m = doit 0 M.empty in M.fold (fun _ n s -> s + if n = 1 then 1 else 0) m 0 |> Printf.printf "%d\n"