#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 EOF;
int getchar();
int /*<<< orphan*/ printf(char *, ...);
int main() {
  int count[20] = {0};
  int c, len = 0, max = 0;
  int state = 0;
  int i = 0, j = 0;
  while ((c = getchar()) != EOF) {
    if (c == ' ' || c == '\t' || c == '\n') {
      if (state == 1 && len >= 1 && len < 20) {
        count[len]++;
        if (count[len] > max) {
          max = count[len];
        }
      }
      len = 0;
      state = 0;
    } else if (state == 0) {
      state = 1;
      len++;
    } else {
      len++;
    }
  }
  printf("\n");
  for (i = max; i >= 1; i--) {
    for (j = 1; j <= 20; j++) {
      if (count[j] > i) {
        printf("  *");
      } else {
        printf("   ");
      }
    }
    printf("\n");
  }
  for (j = 1; j <= 20; j++) {
    printf("---");
  }
  printf("\n");
  for (j = 1; j <= 20; j++) {
    printf("%3d", j);
  }
  printf("\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x60(%rbp),%rdi
xor    %esi,%esi
mov    $0x50,%edx
call   1040 <memset@plt>
movl   $0x0,-0x68(%rbp)
movl   $0x0,-0x6c(%rbp)
movl   $0x0,-0x70(%rbp)
movl   $0x0,-0x74(%rbp)
movl   $0x0,-0x78(%rbp)
mov    $0x0,%al
call   1050 <getchar@plt>
mov    %eax,-0x64(%rbp)
mov    0x2e62(%rip),%rcx
cmp    (%rcx),%eax
je     123f <main+0x10f>
cmpl   $0x20,-0x64(%rbp)
je     11ac <main+0x7c>
cmpl   $0x9,-0x64(%rbp)
je     11ac <main+0x7c>
cmpl   $0xa,-0x64(%rbp)
jne    120d <main+0xdd>
cmpl   $0x1,-0x70(%rbp)
jne    11fa <main+0xca>
cmpl   $0x1,-0x68(%rbp)
jl     11fa <main+0xca>
cmpl   $0x14,-0x68(%rbp)
jge    11fa <main+0xca>
movslq -0x68(%rbp),%rax
mov    -0x60(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0x60(%rbp,%rax,4)
movslq -0x68(%rbp),%rax
mov    -0x60(%rbp,%rax,4),%eax
cmp    -0x6c(%rbp),%eax
jle    11f5 <main+0xc5>
movslq -0x68(%rbp),%rax
mov    -0x60(%rbp,%rax,4),%eax
mov    %eax,-0x6c(%rbp)
jmp    11fa <main+0xca>
movl   $0x0,-0x68(%rbp)
movl   $0x0,-0x70(%rbp)
jmp    123a <main+0x10a>
cmpl   $0x0,-0x70(%rbp)
jne    122c <main+0xfc>
movl   $0x1,-0x70(%rbp)
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
jmp    1235 <main+0x105>
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
jmp    123a <main+0x10a>
jmp    1175 <main+0x45>
lea    0xdba(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x6c(%rbp),%eax
mov    %eax,-0x74(%rbp)
cmpl   $0x1,-0x74(%rbp)
jl     12cf <main+0x19f>
movl   $0x1,-0x78(%rbp)
cmpl   $0x14,-0x78(%rbp)
jg     12b3 <main+0x183>
movslq -0x78(%rbp),%rax
mov    -0x60(%rbp,%rax,4),%eax
cmp    -0x74(%rbp),%eax
jle    1292 <main+0x162>
lea    0xd7c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    12a0 <main+0x170>
lea    0xd6d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    12a5 <main+0x175>
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x78(%rbp)
jmp    1264 <main+0x134>
lea    0xd46(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x74(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x74(%rbp)
jmp    1253 <main+0x123>
movl   $0x1,-0x78(%rbp)
cmpl   $0x14,-0x78(%rbp)
jg     12fc <main+0x1cc>
lea    0xd23(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x78(%rbp)
jmp    12d6 <main+0x1a6>
lea    0xcfd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x1,-0x78(%rbp)
cmpl   $0x14,-0x78(%rbp)
jg     133a <main+0x20a>
mov    -0x78(%rbp),%esi
lea    0xce9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x78(%rbp)
jmp    1311 <main+0x1e1>
lea    0xcbf(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x98,%rsp
xorps  %xmm0,%xmm0
movaps %xmm0,0x80(%rsp)
movaps %xmm0,0x70(%rsp)
movaps %xmm0,0x60(%rsp)
movaps %xmm0,0x50(%rsp)
movaps %xmm0,0x40(%rsp)
xor    %eax,%eax
call   1050 <getchar@plt>
mov    0x2e7a(%rip),%r15
cmp    (%r15),%eax
jne    1182 <main+0x52>
mov    $0xa,%edi
call   1030 <putchar@plt>
jmp    143f <main+0x30f>
movabs $0x100000600,%r14
xor    %r12d,%r12d
xor    %ebx,%ebx
xor    %ecx,%ecx
jmp    11b1 <main+0x81>
cs nopw 0x0(%rax,%rax,1)
nop
xor    %r12d,%r12d
xor    %eax,%eax
call   1050 <getchar@plt>
mov    %ebp,%ecx
cmp    (%r15),%eax
je     11fd <main+0xcd>
cmp    $0x20,%eax
ja     11f0 <main+0xc0>
mov    %eax,%eax
bt     %rax,%r14
jae    11f0 <main+0xc0>
xor    %ebp,%ebp
cmp    $0x1,%r12d
jne    11a0 <main+0x70>
test   %ecx,%ecx
jle    11a0 <main+0x70>
cmp    $0x13,%ecx
jg     11a0 <main+0x70>
mov    %ecx,%eax
mov    0x40(%rsp,%rax,4),%ecx
lea    0x1(%rcx),%edx
mov    %edx,0x40(%rsp,%rax,4)
cmp    %ebx,%ecx
cmovge %edx,%ebx
jmp    11a0 <main+0x70>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
add    $0x1,%ecx
mov    $0x1,%r12d
mov    %ecx,%ebp
jmp    11a3 <main+0x73>
mov    $0xa,%edi
call   1030 <putchar@plt>
test   %ebx,%ebx
jle    143f <main+0x30f>
mov    0x44(%rsp),%eax
mov    %eax,0x3c(%rsp)
mov    0x48(%rsp),%eax
mov    %eax,0x38(%rsp)
mov    0x4c(%rsp),%eax
mov    %eax,0x34(%rsp)
mov    0x50(%rsp),%eax
mov    %eax,0x30(%rsp)
mov    0x54(%rsp),%eax
mov    %eax,0x2c(%rsp)
mov    0x58(%rsp),%eax
mov    %eax,0x28(%rsp)
mov    0x5c(%rsp),%eax
mov    %eax,0x24(%rsp)
mov    0x60(%rsp),%eax
mov    %eax,0x20(%rsp)
mov    0x64(%rsp),%eax
mov    %eax,0x1c(%rsp)
mov    0x68(%rsp),%eax
mov    %eax,0x18(%rsp)
mov    0x6c(%rsp),%eax
mov    %eax,0x14(%rsp)
mov    0x70(%rsp),%eax
mov    %eax,0x10(%rsp)
mov    0x74(%rsp),%eax
mov    %eax,0xc(%rsp)
mov    0x78(%rsp),%eax
mov    %eax,0x8(%rsp)
mov    0x7c(%rsp),%eax
mov    %eax,0x4(%rsp)
mov    0x80(%rsp),%eax
mov    %eax,(%rsp)
mov    0x84(%rsp),%r15d
mov    0x88(%rsp),%r12d
mov    0x8c(%rsp),%r13d
lea    0xd50(%rip),%rbp
lea    0xd4d(%rip),%r14
nopw   0x0(%rax,%rax,1)
cmp    %ebx,0x3c(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x38(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x34(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x30(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x2c(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x28(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x24(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x20(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x1c(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x18(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x14(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x10(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0xc(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x8(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x4(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,%r15d
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,%r12d
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,%r13d
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    %ebx,0x90(%rsp)
mov    %r14,%rdi
cmovg  %rbp,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    -0x1(%rbx),%eax
cmp    $0x1,%ebx
mov    %eax,%ebx
jg     12c0 <main+0x190>
lea    0xbc2(%rip),%rbx
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xaed(%rip),%rbx
mov    %rbx,%rdi
mov    $0x1,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x3,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x4,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x5,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x6,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x7,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x8,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x9,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0xa,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0xb,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0xc,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0xd,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0xe,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0xf,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x10,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x11,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x12,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x13,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    $0x14,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
add    $0x98,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@EOF = global i32 0
@.str = [2 x i8] c"\0A\00"
@.str.1 = [4 x i8] c" *\00"
@.str.2 = [4 x i8] c" \00"
@.str.3 = [4 x i8] c"---\00"
@.str.4 = [4 x i8] c"%3d\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [20 x i32]
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
store i32 0, i32* %1
%9 = bitcast [20 x i32]* %2 to i8*
store i32 0, i32* %4
store i32 0, i32* %5
store i32 0, i32* %6
store i32 0, i32* %7
store i32 0, i32* %8
br label %10
10: ; preds = %61, %0
%11 = call i32 (...) @getchar()
store i32 %11, i32* %3
%12 = load i32, i32* @EOF
%13 = icmp ne i32 %11, %12
br i1 %13, label %14, label %62
14: ; preds = %10
%15 = load i32, i32* %3
%16 = icmp eq i32 %15, 32
br i1 %16, label %23, label %17
17: ; preds = %14
%18 = load i32, i32* %3
%19 = icmp eq i32 %18, 9
br i1 %19, label %23, label %20
20: ; preds = %17
%21 = load i32, i32* %3
%22 = icmp eq i32 %21, 10
br i1 %22, label %23, label %51
23: ; preds = %20, %17, %14
%24 = load i32, i32* %6
%25 = icmp eq i32 %24, 1
br i1 %25, label %26, label %50
26: ; preds = %23
%27 = load i32, i32* %4
%28 = icmp sge i32 %27, 1
br i1 %28, label %29, label %50
29: ; preds = %26
%30 = load i32, i32* %4
%31 = icmp slt i32 %30, 20
br i1 %31, label %32, label %50
32: ; preds = %29
%33 = load i32, i32* %4
%34 = sext i32 %33 to i64
%35 = getelementptr inbounds [20 x i32], [20 x i32]* %2, i64 0, i64 %34
%36 = load i32, i32* %35
%37 = add nsw i32 %36, 1
store i32 %37, i32* %35
%38 = load i32, i32* %4
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds [20 x i32], [20 x i32]* %2, i64 0, i64 %39
%41 = load i32, i32* %40
%42 = load i32, i32* %5
%43 = icmp sgt i32 %41, %42
br i1 %43, label %44, label %49
44: ; preds = %32
%45 = load i32, i32* %4
%46 = sext i32 %45 to i64
%47 = getelementptr inbounds [20 x i32], [20 x i32]* %2, i64 0, i64 %46
%48 = load i32, i32* %47
store i32 %48, i32* %5
br label %49
49: ; preds = %44, %32
br label %50
50: ; preds = %49, %29, %26, %23
store i32 0, i32* %4
store i32 0, i32* %6
br label %61
51: ; preds = %20
%52 = load i32, i32* %6
%53 = icmp eq i32 %52, 0
br i1 %53, label %54, label %57
54: ; preds = %51
store i32 1, i32* %6
%55 = load i32, i32* %4
%56 = add nsw i32 %55, 1
store i32 %56, i32* %4
br label %60
57: ; preds = %51
%58 = load i32, i32* %4
%59 = add nsw i32 %58, 1
store i32 %59, i32* %4
br label %60
60: ; preds = %57, %54
br label %61
61: ; preds = %60, %50
br label %10
62: ; preds = %10
%63 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%64 = load i32, i32* %5
store i32 %64, i32* %7
br label %65
65: ; preds = %89, %62
%66 = load i32, i32* %7
%67 = icmp sge i32 %66, 1
br i1 %67, label %68, label %92
68: ; preds = %65
store i32 1, i32* %8
br label %69
69: ; preds = %84, %68
%70 = load i32, i32* %8
%71 = icmp sle i32 %70, 20
br i1 %71, label %72, label %87
72: ; preds = %69
%73 = load i32, i32* %8
%74 = sext i32 %73 to i64
%75 = getelementptr inbounds [20 x i32], [20 x i32]* %2, i64 0, i64 %74
%76 = load i32, i32* %75
%77 = load i32, i32* %7
%78 = icmp sgt i32 %76, %77
br i1 %78, label %79, label %81
79: ; preds = %72
%80 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
br label %83
81: ; preds = %72
%82 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
br label %83
83: ; preds = %81, %79
br label %84
84: ; preds = %83
%85 = load i32, i32* %8
%86 = add nsw i32 %85, 1
store i32 %86, i32* %8
br label %69
87: ; preds = %69
%88 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %89
89: ; preds = %87
%90 = load i32, i32* %7
%91 = add nsw i32 %90, -1
store i32 %91, i32* %7
br label %65
92: ; preds = %65
store i32 1, i32* %8
br label %93
93: ; preds = %98, %92
%94 = load i32, i32* %8
%95 = icmp sle i32 %94, 20
br i1 %95, label %96, label %101
96: ; preds = %93
%97 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
br label %98
98: ; preds = %96
%99 = load i32, i32* %8
%100 = add nsw i32 %99, 1
store i32 %100, i32* %8
br label %93
101: ; preds = %93
%102 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %8
br label %103
103: ; preds = %109, %101
%104 = load i32, i32* %8
%105 = icmp sle i32 %104, 20
br i1 %105, label %106, label %112
106: ; preds = %103
%107 = load i32, i32* %8
%108 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 %107)
br label %109
109: ; preds = %106
%110 = load i32, i32* %8
%111 = add nsw i32 %110, 1
store i32 %111, i32* %8
br label %103
112: ; preds = %103
%113 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@EOF = global i32 0
@.str.1 = [4 x i8] c" *\00"
@.str.2 = [4 x i8] c" \00"
@.str.3 = [4 x i8] c"---\00"
@.str.4 = [4 x i8] c"%3d\00"
define i32 @main() {
%1 = alloca [20 x i32]
%2 = bitcast [20 x i32]* %1 to i8*
%3 = tail call i32 (...) @getchar()
%4 = load i32, i32* @EOF
%5 = icmp eq i32 %3, %4
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = tail call i32 @putchar(i32 10)
br label %144
8: ; preds = %0, %28
%9 = phi i32 [ %32, %28 ], [ %3, %0 ]
%10 = phi i32 [ %31, %28 ], [ 0, %0 ]
%11 = phi i32 [ %30, %28 ], [ 0, %0 ]
%12 = phi i32 [ %29, %28 ], [ 0, %0 ]
switch i32 %9, label %26 [
i32 32, label %13
i32 10, label %13
i32 9, label %13
]
13: ; preds = %8, %8, %8
%14 = icmp eq i32 %10, 1
%15 = icmp sgt i32 %12, 0
%16 = select i1 %14, i1 %15, i1 false
%17 = icmp slt i32 %12, 20
%18 = select i1 %16, i1 %17, i1 false
br i1 %18, label %19, label %28
19: ; preds = %13
%20 = zext i32 %12 to i64
%21 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 %20
%22 = load i32, i32* %21
%23 = add nsw i32 %22, 1
store i32 %23, i32* %21
%24 = icmp slt i32 %22, %11
%25 = select i1 %24, i32 %11, i32 %23
br label %28
26: ; preds = %8
%27 = add nsw i32 %12, 1
br label %28
28: ; preds = %26, %19, %13
%29 = phi i32 [ 0, %19 ], [ 0, %13 ], [ %27, %26 ]
%30 = phi i32 [ %25, %19 ], [ %11, %13 ], [ %11, %26 ]
%31 = phi i32 [ 0, %19 ], [ 0, %13 ], [ 1, %26 ]
%32 = tail call i32 (...) @getchar()
%33 = load i32, i32* @EOF
%34 = icmp eq i32 %32, %33
br i1 %34, label %35, label %8
35: ; preds = %28
%36 = tail call i32 @putchar(i32 10)
%37 = icmp sgt i32 %30, 0
br i1 %37, label %38, label %144
38: ; preds = %35
%39 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 1
%40 = load i32, i32* %39
%41 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 2
%42 = load i32, i32* %41
%43 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 3
%44 = load i32, i32* %43
%45 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 4
%46 = load i32, i32* %45
%47 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 5
%48 = load i32, i32* %47
%49 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 6
%50 = load i32, i32* %49
%51 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 7
%52 = load i32, i32* %51
%53 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 8
%54 = load i32, i32* %53
%55 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 9
%56 = load i32, i32* %55
%57 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 10
%58 = load i32, i32* %57
%59 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 11
%60 = load i32, i32* %59
%61 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 12
%62 = load i32, i32* %61
%63 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 13
%64 = load i32, i32* %63
%65 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 14
%66 = load i32, i32* %65
%67 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 15
%68 = load i32, i32* %67
%69 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 16
%70 = load i32, i32* %69
%71 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 17
%72 = load i32, i32* %71
%73 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 18
%74 = load i32, i32* %73
%75 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 19
%76 = load i32, i32* %75
%77 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 20
br label %78
78: ; preds = %38, %78
%79 = phi i32 [ %142, %78 ], [ %30, %38 ]
%80 = icmp sgt i32 %40, %79
%81 = select i1 %80, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%82 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %81)
%83 = icmp sgt i32 %42, %79
%84 = select i1 %83, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%85 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %84)
%86 = icmp sgt i32 %44, %79
%87 = select i1 %86, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%88 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %87)
%89 = icmp sgt i32 %46, %79
%90 = select i1 %89, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%91 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %90)
%92 = icmp sgt i32 %48, %79
%93 = select i1 %92, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%94 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %93)
%95 = icmp sgt i32 %50, %79
%96 = select i1 %95, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%97 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %96)
%98 = icmp sgt i32 %52, %79
%99 = select i1 %98, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%100 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %99)
%101 = icmp sgt i32 %54, %79
%102 = select i1 %101, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%103 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %102)
%104 = icmp sgt i32 %56, %79
%105 = select i1 %104, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%106 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %105)
%107 = icmp sgt i32 %58, %79
%108 = select i1 %107, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%109 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %108)
%110 = icmp sgt i32 %60, %79
%111 = select i1 %110, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%112 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %111)
%113 = icmp sgt i32 %62, %79
%114 = select i1 %113, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%115 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %114)
%116 = icmp sgt i32 %64, %79
%117 = select i1 %116, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%118 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %117)
%119 = icmp sgt i32 %66, %79
%120 = select i1 %119, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%121 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %120)
%122 = icmp sgt i32 %68, %79
%123 = select i1 %122, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%124 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %123)
%125 = icmp sgt i32 %70, %79
%126 = select i1 %125, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%127 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %126)
%128 = icmp sgt i32 %72, %79
%129 = select i1 %128, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%130 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %129)
%131 = icmp sgt i32 %74, %79
%132 = select i1 %131, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%133 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %132)
%134 = icmp sgt i32 %76, %79
%135 = select i1 %134, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%136 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %135)
%137 = load i32, i32* %77
%138 = icmp sgt i32 %137, %79
%139 = select i1 %138, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0)
%140 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %139)
%141 = tail call i32 @putchar(i32 10)
%142 = add nsw i32 %79, -1
%143 = icmp sgt i32 %79, 1
br i1 %143, label %78, label %144
144: ; preds = %78, %6, %35
%145 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%146 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%147 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%148 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%149 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%150 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%151 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%152 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%153 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%154 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%155 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%156 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%157 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%158 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%159 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%160 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%161 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%162 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%163 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%164 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
%165 = tail call i32 @putchar(i32 10)
%166 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 1)
%167 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 2)
%168 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 3)
%169 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 4)
%170 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 5)
%171 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 6)
%172 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 7)
%173 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 8)
%174 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 9)
%175 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 10)
%176 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 11)
%177 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 12)
%178 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 13)
%179 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 14)
%180 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 15)
%181 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 16)
%182 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 17)
%183 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 18)
%184 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 19)
%185 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 20)
%186 = tail call i32 @putchar(i32 10)
ret i32 0
}