#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 */
scalar_t__ EOF;
int c(int, int);
int /*<<< orphan*/ printf(char *, ...);
scalar_t__ scanf(char *, int *);
int main(int argc, const char *argv[]) {
  int n, i, j;
  while (scanf("%d", &n) != EOF) {
    for (i = 0; i < n; i++) {
      for (j = 0; j <= i - 1; j++)
        printf("%d ", c(i, j));
      printf("%d\n", c(i, j));
    }
    printf("\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xeb3(%rip),%rdi
lea    -0x14(%rbp),%rsi
call   1050 <scanf@plt>
mov    0x2e8b(%rip),%rcx
cmp    (%rcx),%rax
je     11f6 <main+0xc6>
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    11e3 <main+0xb3>
movl   $0x0,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
mov    -0x18(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jg     11ba <main+0x8a>
mov    -0x18(%rbp),%edi
mov    -0x1c(%rbp),%esi
call   1040 <c@plt>
mov    %eax,%esi
lea    0xe5e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1180 <main+0x50>
mov    -0x18(%rbp),%edi
mov    -0x1c(%rbp),%esi
call   1040 <c@plt>
mov    %eax,%esi
lea    0xe39(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    116d <main+0x3d>
lea    0xe1f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1146 <main+0x16>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
lea    0xeae(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1060 <scanf@plt>
mov    0x2e85(%rip),%rcx
cmp    (%rcx),%rax
jne    1179 <main+0x39>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
lea    0xe87(%rip),%r14
lea    0xe7c(%rip),%r13
lea    0xe72(%rip),%r15
lea    0x4(%rsp),%r12
jmp    11c1 <main+0x81>
cs nopw 0x0(%rax,%rax,1)
nop
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %r15,%rdi
mov    %r12,%rsi
call   1060 <scanf@plt>
mov    0x2e2c(%rip),%rcx
cmp    (%rcx),%rax
je     1168 <main+0x28>
cmpl   $0x0,0x4(%rsp)
jle    11a0 <main+0x60>
xor    %ebp,%ebp
jmp    11ee <main+0xae>
nopl   0x0(%rax)
mov    %ebp,%edi
mov    %ebp,%esi
call   1050 <c@plt>
mov    %r14,%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebp
cmp    0x4(%rsp),%ebp
jge    11a0 <main+0x60>
test   %ebp,%ebp
je     11d0 <main+0x90>
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %ebp,%edi
mov    %ebx,%esi
call   1050 <c@plt>
mov    %r13,%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebx
cmp    %ebx,%ebp
jne    1200 <main+0xc0>
jmp    11d0 <main+0x90>

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

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