program name
    use,intrinsic :: iso_fortran_env
    implicit none
    integer(int32):: n,i
    integer(int32), allocatable:: a(:), josi(:)

    read*, n
    allocate(a(n),josi(0:n))
    read*, a(2:)

    josi(:) = 0
    do i=1,n
        josi(a(i)) = josi(a(i)) + 1
    end do

    do i=1,n
        print'(i0)', josi(i)
    end do

end program name