program main
  
  implicit none
  integer(8) :: n
  integer(8),allocatable :: a(:)
  integer(8),allocatable :: b(:)
  integer :: ans, i
  
  read(*,*) n
  allocate(a(1:n))
  allocate(b(1:n))
  read(*,*) a(2:n)
  
  b = 0
  do i = 2, n
    b(a(i)) = b(a(i)) + 1
  end do
  do i = 1, n
    print*,b(i)
  end do
  
  
  
end program main
