   program abc164c
      implicit none
      integer::n
      character(10),allocatable::s(:)
      integer::i,j,count
      character(10)::tmps

         read *, n
         allocate(s(n))
         do i=1,n
            read *,s(i)
         end do

         do i=1,n-1
            do j=i+1,n
               if (s(i)>s(j)) then
                  tmps=s(j)
                  s(j)=s(i)
                  s(i)=tmps
               end if
            end do
         end do

         count=1
         do i=1,n-1
            if (s(i)==s(i+1)) cycle
            count=count+1
         end do

         print *, count

   end program abc164c