#include<stdio.h>

int main(void){
  int N; scanf("%d",&N);
  int A[200010];
  for(int i = 2;i <= N;i++){
    scanf("%d",&A[i]);
  }

  int count[200010];

  for(int i = 2;i <= N;i++){count[A[i]] += 1;}

  for(int i = 1;i <= N;i++){printf("%d",count[i]);}

  return 0;
}
