import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    }
} Main public static void main(String[] args) {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    } main {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int[] member = new int[N]; member new int[N] N for(int i=0;i<N;i++) {
    		member[i] = 0;
    	} int i=0; int i=0; i 0 i<N i N i++ i++ i {
    		member[i] = 0;
    	} {
    		member[i] = 0;
    	} member[i] = 0 member[i] member i 0 for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	} int i=0; int i=0; i 0 i<N-1 i N-1 N 1 i++ i++ i {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	} {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	} int joshiNumber = sc.nextInt(); joshiNumber sc.nextInt() sc.nextInt sc member[joshiNumber-1] = member[joshiNumber-1] + 1 member[joshiNumber-1] member joshiNumber-1 joshiNumber 1 member[joshiNumber-1] + 1 member[joshiNumber-1] member joshiNumber-1 joshiNumber 1 1 for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	} int i=0; int i=0; i 0 i<N i N i++ i++ i {
    		System.out.println(member[i]);
    	} {
    		System.out.println(member[i]);
    	} System.out.println(member[i]) System.out.println System.out System System.out member[i] member i String[] args args public class Main {
    public static void main(String[] args) {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    }
} public class Main {
    public static void main(String[] args) {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        //コード
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();

    	int[] member = new int[N];


    	for(int i=0;i<N;i++) {
    		member[i] = 0;
    	}

    	for(int i=0;i<N-1;i++) {
    		int joshiNumber = sc.nextInt();
    		member[joshiNumber-1] = member[joshiNumber-1] + 1;
    	}
    	for(int i=0;i<N;i++) {
    		System.out.println(member[i]);
    	}

    }
}