#include <stdio.h>

int main(void){

  long n;
  scanf("%ld", &n);
  long a[n+1];
  for (long i = 2; i <= n; i++) {
    scanf("%ld", &a[i]);
  }

  long list[n+1];
  for (int i = 1; i <= n; i++) {
    list[i] = 0;
  }
  for (int i = n; i >= 2; i--) {
    list[a[i]]++;
  }
  for (int i = 1; i <= n; i++) {
    printf("%ld\n", list[i]);
  }

  return 0;
}