#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 main() {
  int i, j = 0, a = 1;
  for (i = 1; i <= 4; i++) {
    for (j = 0; j < 7; j++) {
      if (i == 1) {
        printf("\t");
        if (j == 3) {
          printf("%d", a);
          a++;
        }
      }
      if (i == 2) {
        printf("\t");
        if (j == 2 || j == 4) {
          printf("%d", a);
          a++;
        }
      }
      if (i == 3) {
        printf("\t");
        if (j = 1 || j == 3 || j == 5) {
          printf("%d", a);
          a++;
        }
      }
      if (i == 4) {
        if (j == 0 || j == 2 || j == 4 || j == 6) {
          printf("%d", a);
          a++;
        }
        printf("\t");
      }
    }
    printf("\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0xc(%rbp)
movl   $0x1,-0x10(%rbp)
movl   $0x1,-0x8(%rbp)
cmpl   $0x4,-0x8(%rbp)
jg     12b1 <main+0x1a1>
movl   $0x0,-0xc(%rbp)
cmpl   $0x7,-0xc(%rbp)
jge    1295 <main+0x185>
cmpl   $0x1,-0x8(%rbp)
jne    1190 <main+0x80>
lea    0xea0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
cmpl   $0x3,-0xc(%rbp)
jne    118b <main+0x7b>
mov    -0x10(%rbp),%esi
lea    0xe87(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1190 <main+0x80>
cmpl   $0x2,-0x8(%rbp)
jne    11db <main+0xcb>
lea    0xe5f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
cmpl   $0x2,-0xc(%rbp)
je     11bc <main+0xac>
cmpl   $0x4,-0xc(%rbp)
jne    11d6 <main+0xc6>
mov    -0x10(%rbp),%esi
lea    0xe3c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    11db <main+0xcb>
cmpl   $0x3,-0x8(%rbp)
jne    1228 <main+0x118>
lea    0xe14(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x1,-0xc(%rbp)
mov    $0x1,%al
test   $0x1,%al
jne    1209 <main+0xf9>
jmp    1223 <main+0x113>
mov    -0x10(%rbp),%esi
lea    0xdef(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    1228 <main+0x118>
cmpl   $0x4,-0x8(%rbp)
jne    1282 <main+0x172>
cmpl   $0x0,-0xc(%rbp)
je     125a <main+0x14a>
cmpl   $0x2,-0xc(%rbp)
je     125a <main+0x14a>
cmpl   $0x4,-0xc(%rbp)
je     125a <main+0x14a>
cmpl   $0x6,-0xc(%rbp)
jne    1274 <main+0x164>
mov    -0x10(%rbp),%esi
lea    0xd9e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
lea    0xd85(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1287 <main+0x177>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1145 <main+0x35>
lea    0xd69(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1134 <main+0x24>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    $0x1,%ebx
lea    0xec9(%rip),%r15
lea    0xed2(%rip),%r14
mov    $0x55,%r12d
mov    $0x1,%r13d
jmp    1168 <main+0x48>
nopl   0x0(%rax)
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x1,%r13d
cmp    $0x5,%r13d
je     1239 <main+0x119>
xor    %ebp,%ebp
jmp    119a <main+0x7a>
nopl   0x0(%rax)
mov    $0x9,%edi
call   1030 <putchar@plt>
mov    %r14,%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebx
mov    $0x1,%ebp
xchg   %ax,%ax
lea    0x1(%rbp),%eax
cmp    $0x6,%ebp
mov    %eax,%ebp
jge    1150 <main+0x30>
lea    -0x1(%r13),%eax
cmp    $0x3,%eax
ja     1190 <main+0x70>
movslq (%r15,%rax,4),%rax
add    %r15,%rax
jmp    *%rax
mov    $0x9,%edi
call   1030 <putchar@plt>
cmp    $0x3,%ebp
jne    1190 <main+0x70>
mov    %r14,%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebx
mov    $0x3,%ebp
jmp    1190 <main+0x70>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    $0x9,%edi
call   1030 <putchar@plt>
cmp    $0x4,%ebp
je     11f4 <main+0xd4>
cmp    $0x2,%ebp
jne    1190 <main+0x70>
mov    %r14,%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebx
jmp    1190 <main+0x70>
cs nopw 0x0(%rax,%rax,1)
nop
cmp    $0x6,%ebp
ja     122a <main+0x10a>
bt     %ebp,%r12d
jae    122a <main+0x10a>
mov    %r14,%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebx
mov    $0x9,%edi
call   1030 <putchar@plt>
jmp    1190 <main+0x70>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [2 x i8] c"\09\00"
@.str.1 = [3 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
store i32 0, i32* %1
store i32 0, i32* %3
store i32 1, i32* %4
store i32 1, i32* %2
br label %5
5: ; preds = %80, %0
%6 = load i32, i32* %2
%7 = icmp sle i32 %6, 4
br i1 %7, label %8, label %83
8: ; preds = %5
store i32 0, i32* %3
br label %9
9: ; preds = %75, %8
%10 = load i32, i32* %3
%11 = icmp slt i32 %10, 7
br i1 %11, label %12, label %78
12: ; preds = %9
%13 = load i32, i32* %2
%14 = icmp eq i32 %13, 1
br i1 %14, label %15, label %25
15: ; preds = %12
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%17 = load i32, i32* %3
%18 = icmp eq i32 %17, 3
br i1 %18, label %19, label %24
19: ; preds = %15
%20 = load i32, i32* %4
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32 %20)
%22 = load i32, i32* %4
%23 = add nsw i32 %22, 1
store i32 %23, i32* %4
br label %24
24: ; preds = %19, %15
br label %25
25: ; preds = %24, %12
%26 = load i32, i32* %2
%27 = icmp eq i32 %26, 2
br i1 %27, label %28, label %41
28: ; preds = %25
%29 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%30 = load i32, i32* %3
%31 = icmp eq i32 %30, 2
br i1 %31, label %35, label %32
32: ; preds = %28
%33 = load i32, i32* %3
%34 = icmp eq i32 %33, 4
br i1 %34, label %35, label %40
35: ; preds = %32, %28
%36 = load i32, i32* %4
%37 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32 %36)
%38 = load i32, i32* %4
%39 = add nsw i32 %38, 1
store i32 %39, i32* %4
br label %40
40: ; preds = %35, %32
br label %41
41: ; preds = %40, %25
%42 = load i32, i32* %2
%43 = icmp eq i32 %42, 3
br i1 %43, label %44, label %52
44: ; preds = %41
%45 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %3
br i1 true, label %46, label %51
46: ; preds = %44
%47 = load i32, i32* %4
%48 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32 %47)
%49 = load i32, i32* %4
%50 = add nsw i32 %49, 1
store i32 %50, i32* %4
br label %51
51: ; preds = %46, %44
br label %52
52: ; preds = %51, %41
%53 = load i32, i32* %2
%54 = icmp eq i32 %53, 4
br i1 %54, label %55, label %74
55: ; preds = %52
%56 = load i32, i32* %3
%57 = icmp eq i32 %56, 0
br i1 %57, label %67, label %58
58: ; preds = %55
%59 = load i32, i32* %3
%60 = icmp eq i32 %59, 2
br i1 %60, label %67, label %61
61: ; preds = %58
%62 = load i32, i32* %3
%63 = icmp eq i32 %62, 4
br i1 %63, label %67, label %64
64: ; preds = %61
%65 = load i32, i32* %3
%66 = icmp eq i32 %65, 6
br i1 %66, label %67, label %72
67: ; preds = %64, %61, %58, %55
%68 = load i32, i32* %4
%69 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32 %68)
%70 = load i32, i32* %4
%71 = add nsw i32 %70, 1
store i32 %71, i32* %4
br label %72
72: ; preds = %67, %64
%73 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %74
74: ; preds = %72, %52
br label %75
75: ; preds = %74
%76 = load i32, i32* %3
%77 = add nsw i32 %76, 1
store i32 %77, i32* %3
br label %9
78: ; preds = %9
%79 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %80
80: ; preds = %78
%81 = load i32, i32* %2
%82 = add nsw i32 %81, 1
store i32 %82, i32* %2
br label %5
83: ; preds = %5
ret i32 0
}

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