program abc085b
  implicit none
  integer n
  integer,allocatable :: d(:)
  logical,allocatable :: l(:)
  read *, n
  allocate(d(n),l(n))
  read *, d
  l = .false.
  l(d) = .true.
  print *, count(l)
end program abc085b
