#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 g(int);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int a, b, c, d, h, i, j;
  scanf("%d", &h);
  while (h--) {
    if (h != 0) {
      while (a < 50) {
        if (b < c)
          d = 100;
        else
          d = 50;
        g(g(g(d)));
      }
    } else {
      for (i = 0; i < d; i++) {
        j = j + i;
      }
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x18(%rbp),%rsi
call   1040 <scanf@plt>
mov    -0x18(%rbp),%eax
mov    %eax,%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x18(%rbp)
cmp    $0x0,%eax
je     11df <main+0xbf>
cmpl   $0x0,-0x18(%rbp)
je     11ab <main+0x8b>
jmp    1162 <main+0x42>
cmpl   $0x32,-0x8(%rbp)
jge    11a6 <main+0x86>
mov    -0xc(%rbp),%eax
cmp    -0x10(%rbp),%eax
jge    1184 <main+0x64>
movl   $0x64,-0x14(%rbp)
jmp    118b <main+0x6b>
movl   $0x32,-0x14(%rbp)
mov    -0x14(%rbp),%edi
call   1030 <g@plt>
mov    %eax,%edi
call   1030 <g@plt>
mov    %eax,%edi
call   1030 <g@plt>
jmp    1162 <main+0x42>
jmp    11da <main+0xba>
movl   $0x0,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    11d5 <main+0xb5>
mov    -0x20(%rbp),%eax
add    -0x1c(%rbp),%eax
mov    %eax,-0x20(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    11b2 <main+0x92>
jmp    11da <main+0xba>
jmp    113f <main+0x1f>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee8(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1030 <scanf@plt>
xor    %eax,%eax
pop    %rcx
ret

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
ret i32 0
}