#include<bits/stdc++.h>
typedef long long ll;
using namespace std;
void io(){ ios_base::sync_with_stdio(false);cin.tie(NULL);  cout.tie(NULL);}
int main()
{
    //io();
    ll tt;
    tt=1;
    cout<<fixed;
    while(tt--)
    {
        ll n;
        cin>>n;
        vector<ll> gr[n];
        for(int i=0;i<n-1;i++)
        {
            ll x;
            cin>>x;x--;
            gr[x].push_back(i);
        }
        for(int i=0;i<n;i++)
            cout<<gr[i].size()<<"\n";
    }
}
