import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;

class Main {
    public static void main(String[] args){
        try{
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        }catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        }
    }
    static boolean check(int[] arr){
        int odd=0;
        for(int i=0;i<arr.length;i++){
            if(arr[i]%2!=0){
                odd++;
            }
        }
        if(odd<=1){
            return true;
        }
        return false;
    }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.ArrayList; ArrayList java.util import java.util.HashMap; HashMap java.util import java.util.HashSet; HashSet java.util import java.util.List; List java.util class Main {
    public static void main(String[] args){
        try{
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        }catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        }
    }
    static boolean check(int[] arr){
        int odd=0;
        for(int i=0;i<arr.length;i++){
            if(arr[i]%2!=0){
                odd++;
            }
        }
        if(odd<=1){
            return true;
        }
        return false;
    }
} Main public static void main(String[] args){
        try{
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        }catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        }
    } main {
        try{
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        }catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        }
    } try{
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        }catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        } catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        } Exception e {
            System.out.println("KKKK "+e.getMessage());
        } System.out.println("KKKK "+e.getMessage()) System.out.println System.out System System.out "KKKK "+e.getMessage() "KKKK " e.getMessage() e.getMessage e {
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        } BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) int n=Integer.parseInt(br.readLine()); n Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br String[] ss=br.readLine().split(" "); ss br.readLine().split(" ") br.readLine().split br.readLine() br.readLine br " " int[] arr=new int[n]; arr new int[n] n int[] c=new int[n]; c new int[n] n for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            } int j=0; int j=0; j 0 j<n-1 j n-1 n 1 j++ j++ j {
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            } {
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            } arr[j]=Integer.parseInt(ss[j])-1 arr[j] arr j Integer.parseInt(ss[j])-1 Integer.parseInt(ss[j]) Integer.parseInt Integer ss[j] ss j 1 c[arr[j]]+=1 c[arr[j]] c arr[j] arr j 1 for(int j=0;j<n;j++){
                System.out.println(c[j]);
            } int j=0; int j=0; j 0 j<n j n j++ j++ j {
                System.out.println(c[j]);
            } {
                System.out.println(c[j]);
            } System.out.println(c[j]) System.out.println System.out System System.out c[j] c j String[] args args static boolean check(int[] arr){
        int odd=0;
        for(int i=0;i<arr.length;i++){
            if(arr[i]%2!=0){
                odd++;
            }
        }
        if(odd<=1){
            return true;
        }
        return false;
    } check {
        int odd=0;
        for(int i=0;i<arr.length;i++){
            if(arr[i]%2!=0){
                odd++;
            }
        }
        if(odd<=1){
            return true;
        }
        return false;
    } int odd=0; odd 0 for(int i=0;i<arr.length;i++){
            if(arr[i]%2!=0){
                odd++;
            }
        } int i=0; int i=0; i 0 i<arr.length i arr.length arr arr.length i++ i++ i {
            if(arr[i]%2!=0){
                odd++;
            }
        } {
            if(arr[i]%2!=0){
                odd++;
            }
        } if(arr[i]%2!=0){
                odd++;
            } arr[i]%2!=0 arr[i]%2 arr[i] arr i 2 0 {
                odd++;
            } odd++ odd if(odd<=1){
            return true;
        } odd<=1 odd 1 {
            return true;
        } return true; true return false; false int[] arr arr
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;

class Main {
    public static void main(String[] args){
        try{
            BufferedReader br=new BufferedReader(new InputStreamReader(System.in));

            int n=Integer.parseInt(br.readLine());
            String[] ss=br.readLine().split(" ");
            int[] arr=new int[n];
            int[] c=new int[n];
            //System.out.println(n);
            for(int j=0;j<n-1;j++){
                arr[j]=Integer.parseInt(ss[j])-1;
                //System.out.println(arr[j]);
                c[arr[j]]+=1;

            }
            for(int j=0;j<n;j++){
                System.out.println(c[j]);
            }



        }catch(Exception e){
            System.out.println("KKKK "+e.getMessage());
        }
    }
    static boolean check(int[] arr){
        int odd=0;
        for(int i=0;i<arr.length;i++){
            if(arr[i]%2!=0){
                odd++;
            }
        }
        if(odd<=1){
            return true;
        }
        return false;
    }
}