#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int n, i, t;
  scanf("%d", &n);
  int a[100];
  for (i = 0; i < 100; ++i)
    a[i] = 0;
  for (i = 0; i < n; ++i) {
    scanf("%d", &t);
    a[t]++;
  }
  for (i = 0; i < 100; ++i)
    printf("%d ", a[i]);
  printf("\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1a0,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xec7(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
movl   $0x0,-0xc(%rbp)
cmpl   $0x64,-0xc(%rbp)
jge    1170 <main+0x50>
movslq -0xc(%rbp),%rax
movl   $0x0,-0x1a0(%rbp,%rax,4)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1149 <main+0x29>
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11b6 <main+0x96>
lea    0xe76(%rip),%rdi
lea    -0x10(%rbp),%rsi
call   1040 <scanf@plt>
movslq -0x10(%rbp),%rax
mov    -0x1a0(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0x1a0(%rbp,%rax,4)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1177 <main+0x57>
movl   $0x0,-0xc(%rbp)
cmpl   $0x64,-0xc(%rbp)
jge    11ee <main+0xce>
movslq -0xc(%rbp),%rax
mov    -0x1a0(%rbp,%rax,4),%esi
lea    0xe2a(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    11bd <main+0x9d>
lea    0xe12(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x1a0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
sub    $0x1a0,%rsp
lea    0xeae(%rip),%rdi
lea    0x8(%rsp),%rsi
call   1060 <scanf@plt>
lea    0x10(%rsp),%rdi
xor    %ebp,%ebp
mov    $0x190,%edx
xor    %esi,%esi
call   1050 <memset@plt>
cmpl   $0x0,0x8(%rsp)
jle    11ae <main+0x6e>
lea    0xe83(%rip),%r14
lea    0xc(%rsp),%rbx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    %r14,%rdi
mov    %rbx,%rsi
call   1060 <scanf@plt>
movslq 0xc(%rsp),%rax
addl   $0x1,0x10(%rsp,%rax,4)
add    $0x1,%ebp
cmp    0x8(%rsp),%ebp
jl     1190 <main+0x50>
lea    0xe4e(%rip),%rbx
xor    %ebp,%ebp
nopw   0x0(%rax,%rax,1)
mov    0x10(%rsp,%rbp,4),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%rbp
cmp    $0x64,%rbp
jne    11c0 <main+0x80>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
add    $0x1a0,%rsp
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%d \00"
@.str.2 = [2 x i8] c"\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca [100 x i32]
store i32 0, i32* %1
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
store i32 0, i32* %3
br label %7
7: ; preds = %14, %0
%8 = load i32, i32* %3
%9 = icmp slt i32 %8, 100
br i1 %9, label %10, label %17
10: ; preds = %7
%11 = load i32, i32* %3
%12 = sext i32 %11 to i64
%13 = getelementptr inbounds [100 x i32], [100 x i32]* %5, i64 0, i64 %12
store i32 0, i32* %13
br label %14
14: ; preds = %10
%15 = load i32, i32* %3
%16 = add nsw i32 %15, 1
store i32 %16, i32* %3
br label %7
17: ; preds = %7
store i32 0, i32* %3
br label %18
18: ; preds = %29, %17
%19 = load i32, i32* %3
%20 = load i32, i32* %2
%21 = icmp slt i32 %19, %20
br i1 %21, label %22, label %32
22: ; preds = %18
%23 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %4)
%24 = load i32, i32* %4
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds [100 x i32], [100 x i32]* %5, i64 0, i64 %25
%27 = load i32, i32* %26
%28 = add nsw i32 %27, 1
store i32 %28, i32* %26
br label %29
29: ; preds = %22
%30 = load i32, i32* %3
%31 = add nsw i32 %30, 1
store i32 %31, i32* %3
br label %18
32: ; preds = %18
store i32 0, i32* %3
br label %33
33: ; preds = %42, %32
%34 = load i32, i32* %3
%35 = icmp slt i32 %34, 100
br i1 %35, label %36, label %45
36: ; preds = %33
%37 = load i32, i32* %3
%38 = sext i32 %37 to i64
%39 = getelementptr inbounds [100 x i32], [100 x i32]* %5, i64 0, i64 %38
%40 = load i32, i32* %39
%41 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %40)
br label %42
42: ; preds = %36
%43 = load i32, i32* %3
%44 = add nsw i32 %43, 1
store i32 %44, i32* %3
br label %33
45: ; preds = %33
%46 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%d \00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [100 x i32]
%4 = bitcast [100 x i32]* %3 to i8*
%5 = bitcast i32* %1 to i8*
%6 = bitcast i32* %2 to i8*
%7 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%8 = load i32, i32* %1
%9 = icmp sgt i32 %8, 0
br i1 %9, label %10, label %21
10: ; preds = %0, %10
%11 = phi i32 [ %18, %10 ], [ 0, %0 ]
%12 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%13 = load i32, i32* %2
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds [100 x i32], [100 x i32]* %3, i64 0, i64 %14
%16 = load i32, i32* %15
%17 = add nsw i32 %16, 1
store i32 %17, i32* %15
%18 = add nuw nsw i32 %11, 1
%19 = load i32, i32* %1
%20 = icmp slt i32 %18, %19
br i1 %20, label %10, label %21
21: ; preds = %10, %0
br label %22
22: ; preds = %21, %22
%23 = phi i64 [ %27, %22 ], [ 0, %21 ]
%24 = getelementptr inbounds [100 x i32], [100 x i32]* %3, i64 0, i64 %23
%25 = load i32, i32* %24
%26 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %25)
%27 = add nuw nsw i64 %23, 1
%28 = icmp eq i64 %27, 100
br i1 %28, label %29, label %22
29: ; preds = %22
%30 = call i32 @putchar(i32 10)
ret i32 0
}