program main
    implicit none
    integer n,i
    integer,allocatable::a(:),b(:)
    read(*,*) n
    allocate(a(n),b(n))
    read(*,*) a(2:n)
    do i=1,n
        write(*,*) count(a-i==0)
    end do
end program main
