program main
implicit none
integer :: i, j, k
integer :: n
integer , allocatable :: a(:), b(:)

read(*,*) n
allocate( a(n), b(n) )
b(1) = 0
do i = 1, n
   read(*,*) a(i)
   k = 1
   do j = 1, i
      if( a(i) == b(j) ) then
         k = 0
         b(j) = 0
      end if
   end do
   if( k == 1 ) then
      b(i) = a(i)
   else
      b(i) = 0
   end if
end do
j = 0
do i = 1,  n
   if( b(i) /= 0 ) then
      j = j + 1
   end if   
end do
write(*,'(i0)')  j

end program main
