#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*/ getchar();
int /*<<< orphan*/ printf(char *, ...);
main() {
  {
    int brojac, n = 1;
    for (brojac = 1; brojac < 5; ++brojac)
      printf("%d,\n", n = n + brojac);
    printf("%d,\n", n = n / brojac);
    getchar();
  }
  {
    int c = 11;
    printf("%d\n", c / sizeof(int));
    printf("%.1f\n ", (float)c / sizeof(int));
    printf("%d\n", (float)c / sizeof(int));
    getchar();
  }
  {
    int a = 5, b = 6, c = 1, d = 3;
    printf("%d %d %d %d\n", a - b % d, a - d / c, c + d % b, (++a) * ++d + 1);
    getchar();
  }
  {
    int brojac = 0, n = 0;
    while (brojac < 3) {
      printf("%d ", n = (n + 1) * brojac + brojac);
      brojac++;
    }
    printf("\n");
    getchar();
  }
  {
    int a = 3, b = 4, c = 7;
    int d;
    d = (a % b) / (((c / a) - 1) * b) - 1;
    if (d + 1)
      printf("PERO\n");
    else
      printf("MIKO\n");
    getchar();
  }
  {
    int a = 11, b = 4, c = 6, d = 3, e = 2;
    int f, g;
    float i, j;
    f = (d * (a % c++)) - a / b - 1;
    g = (++a * c) % --e + 1;
    i = j = a * (c / d--);
    j = j - a / d;
    printf("f = %d g = %d i = %f j = %f\n", f, g, i, j);
    getchar();
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x1,-0xc(%rbp)
movl   $0x1,-0x8(%rbp)
cmpl   $0x5,-0x8(%rbp)
jge    116f <main+0x4f>
mov    -0xc(%rbp),%esi
add    -0x8(%rbp),%esi
mov    %esi,-0xc(%rbp)
lea    0xeaa(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1140 <main+0x20>
mov    -0xc(%rbp),%eax
cltd
idivl  -0x8(%rbp)
mov    %eax,%esi
mov    %esi,-0xc(%rbp)
lea    0xe82(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <getchar@plt>
movl   $0xb,-0x10(%rbp)
movslq -0x10(%rbp),%rsi
shr    $0x2,%rsi
lea    0xe73(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
cvtsi2ssl -0x10(%rbp),%xmm0
movss  0xe46(%rip),%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe40(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
cvtsi2ssl -0x10(%rbp),%xmm0
movss  0xe23(%rip),%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe2d(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <getchar@plt>
movl   $0x5,-0x14(%rbp)
movl   $0x6,-0x18(%rbp)
movl   $0x1,-0x1c(%rbp)
movl   $0x3,-0x20(%rbp)
mov    -0x14(%rbp),%esi
mov    -0x18(%rbp),%eax
cltd
idivl  -0x20(%rbp)
sub    %edx,%esi
mov    -0x14(%rbp),%eax
mov    %eax,-0x64(%rbp)
mov    -0x20(%rbp),%eax
cltd
idivl  -0x1c(%rbp)
mov    %eax,%ecx
mov    -0x64(%rbp),%eax
sub    %ecx,%eax
mov    %eax,-0x60(%rbp)
mov    -0x1c(%rbp),%ecx
mov    -0x20(%rbp),%eax
cltd
idivl  -0x18(%rbp)
mov    %edx,%eax
mov    -0x60(%rbp),%edx
add    %eax,%ecx
mov    -0x14(%rbp),%r8d
add    $0x1,%r8d
mov    %r8d,-0x14(%rbp)
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
imul   %eax,%r8d
add    $0x1,%r8d
lea    0xda2(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <getchar@plt>
movl   $0x0,-0x24(%rbp)
movl   $0x0,-0x28(%rbp)
cmpl   $0x3,-0x24(%rbp)
jge    12c0 <main+0x1a0>
mov    -0x28(%rbp),%esi
add    $0x1,%esi
imul   -0x24(%rbp),%esi
add    -0x24(%rbp),%esi
mov    %esi,-0x28(%rbp)
lea    0xd72(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    128a <main+0x16a>
lea    0xd40(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <getchar@plt>
movl   $0x3,-0x2c(%rbp)
movl   $0x4,-0x30(%rbp)
movl   $0x7,-0x34(%rbp)
mov    -0x2c(%rbp),%eax
cltd
idivl  -0x30(%rbp)
mov    %edx,-0x68(%rbp)
mov    -0x34(%rbp),%eax
cltd
idivl  -0x2c(%rbp)
mov    %eax,%ecx
mov    -0x68(%rbp),%eax
sub    $0x1,%ecx
imul   -0x30(%rbp),%ecx
cltd
idiv   %ecx
sub    $0x1,%eax
mov    %eax,-0x38(%rbp)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
cmp    $0x0,%eax
je     1332 <main+0x212>
lea    0xcfb(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1340 <main+0x220>
lea    0xcee(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <getchar@plt>
movl   $0xb,-0x3c(%rbp)
movl   $0x4,-0x40(%rbp)
movl   $0x6,-0x44(%rbp)
movl   $0x3,-0x48(%rbp)
movl   $0x2,-0x4c(%rbp)
mov    -0x48(%rbp),%eax
mov    %eax,-0x74(%rbp)
mov    -0x3c(%rbp),%eax
mov    -0x44(%rbp),%ecx
mov    %ecx,%edx
add    $0x1,%edx
mov    %edx,-0x44(%rbp)
cltd
idiv   %ecx
mov    -0x74(%rbp),%eax
imul   %edx,%eax
mov    %eax,-0x70(%rbp)
mov    -0x3c(%rbp),%eax
cltd
idivl  -0x40(%rbp)
mov    %eax,%ecx
mov    -0x70(%rbp),%eax
sub    %ecx,%eax
sub    $0x1,%eax
mov    %eax,-0x50(%rbp)
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
imul   -0x44(%rbp),%eax
mov    -0x4c(%rbp),%ecx
add    $0xffffffff,%ecx
mov    %ecx,-0x4c(%rbp)
cltd
idiv   %ecx
add    $0x1,%edx
mov    %edx,-0x54(%rbp)
mov    -0x3c(%rbp),%eax
mov    %eax,-0x6c(%rbp)
mov    -0x44(%rbp),%eax
mov    -0x48(%rbp),%ecx
mov    %ecx,%edx
add    $0xffffffff,%edx
mov    %edx,-0x48(%rbp)
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x6c(%rbp),%eax
imul   %ecx,%eax
cvtsi2ss %eax,%xmm0
movss  %xmm0,-0x5c(%rbp)
movss  %xmm0,-0x58(%rbp)
movss  -0x5c(%rbp),%xmm0
mov    -0x3c(%rbp),%eax
cltd
idivl  -0x48(%rbp)
cvtsi2ss %eax,%xmm1
subss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x50(%rbp),%esi
mov    -0x54(%rbp),%edx
movss  -0x58(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x5c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
lea    0xc0b(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <getchar@plt>
mov    -0x4(%rbp),%eax
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xed0(%rip),%rbx
mov    %rbx,%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0x4,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0x7,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0xb,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %eax,%eax
call   1060 <getchar@plt>
lea    0xe8c(%rip),%rbx
mov    $0x2,%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe66(%rip),%rdi
movsd  0xe41(%rip),%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
mov    %rbx,%rdi
movsd  0xe2f(%rip),%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
xor    %eax,%eax
call   1060 <getchar@plt>
lea    0xe3e(%rip),%rdi
mov    $0x5,%esi
mov    $0x2,%edx
mov    $0x4,%ecx
mov    $0x19,%r8d
xor    %eax,%eax
call   1050 <printf@plt>
xor    %eax,%eax
call   1060 <getchar@plt>
lea    0xe21(%rip),%rbx
mov    %rbx,%rdi
xor    %esi,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0x2,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    %rbx,%rdi
mov    $0x8,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
call   1060 <getchar@plt>
lea    0xe00(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1060 <getchar@plt>
lea    0xdd0(%rip),%rdi
movsd  0xd9b(%rip),%xmm0
movsd  0xd9b(%rip),%xmm1
mov    $0xc,%esi
mov    $0x1,%edx
mov    $0x2,%al
call   1050 <printf@plt>
xor    %eax,%eax
call   1060 <getchar@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"%d,\0A\00"
@.str.1 = [4 x i8] c"%d\0A\00"
@.str.2 = [7 x i8] c"%.1f\0A \00"
@.str.3 = [13 x i8] c"%d %d %d %d\0A\00"
@.str.4 = [4 x i8] c"%d \00"
@.str.5 = [2 x i8] c"\0A\00"
@.str.6 = [6 x i8] c"PERO\0A\00"
@.str.7 = [6 x i8] c"MIKO\0A\00"
@.str.8 = [29 x i8] c"f = %d g = %d i = %f j = %f\0A\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
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca i32
%20 = alloca i32
%21 = alloca i32
%22 = alloca float
%23 = alloca float
store i32 0, i32* %1
store i32 1, i32* %3
store i32 1, i32* %2
br label %24
24: ; preds = %32, %0
%25 = load i32, i32* %2
%26 = icmp slt i32 %25, 5
br i1 %26, label %27, label %35
27: ; preds = %24
%28 = load i32, i32* %3
%29 = load i32, i32* %2
%30 = add nsw i32 %28, %29
store i32 %30, i32* %3
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %30)
br label %32
32: ; preds = %27
%33 = load i32, i32* %2
%34 = add nsw i32 %33, 1
store i32 %34, i32* %2
br label %24
35: ; preds = %24
%36 = load i32, i32* %3
%37 = load i32, i32* %2
%38 = sdiv i32 %36, %37
store i32 %38, i32* %3
%39 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %38)
%40 = call i32 (...) @getchar()
store i32 11, i32* %4
%41 = load i32, i32* %4
%42 = sext i32 %41 to i64
%43 = udiv i64 %42, 4
%44 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i64 %43)
%45 = load i32, i32* %4
%46 = sitofp i32 %45 to float
%47 = fdiv float %46, 4.000000e+00
%48 = fpext float %47 to double
%49 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.2, i64 0, i64 0), double %48)
%50 = load i32, i32* %4
%51 = sitofp i32 %50 to float
%52 = fdiv float %51, 4.000000e+00
%53 = fpext float %52 to double
%54 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), double %53)
%55 = call i32 (...) @getchar()
store i32 5, i32* %5
store i32 6, i32* %6
store i32 1, i32* %7
store i32 3, i32* %8
%56 = load i32, i32* %5
%57 = load i32, i32* %6
%58 = load i32, i32* %8
%59 = srem i32 %57, %58
%60 = sub nsw i32 %56, %59
%61 = load i32, i32* %5
%62 = load i32, i32* %8
%63 = load i32, i32* %7
%64 = sdiv i32 %62, %63
%65 = sub nsw i32 %61, %64
%66 = load i32, i32* %7
%67 = load i32, i32* %8
%68 = load i32, i32* %6
%69 = srem i32 %67, %68
%70 = add nsw i32 %66, %69
%71 = load i32, i32* %5
%72 = add nsw i32 %71, 1
store i32 %72, i32* %5
%73 = load i32, i32* %8
%74 = add nsw i32 %73, 1
store i32 %74, i32* %8
%75 = mul nsw i32 %72, %74
%76 = add nsw i32 %75, 1
%77 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0), i32 %60, i32 %65, i32 %70, i32 %76)
%78 = call i32 (...) @getchar()
store i32 0, i32* %9
store i32 0, i32* %10
br label %79
79: ; preds = %82, %35
%80 = load i32, i32* %9
%81 = icmp slt i32 %80, 3
br i1 %81, label %82, label %92
82: ; preds = %79
%83 = load i32, i32* %10
%84 = add nsw i32 %83, 1
%85 = load i32, i32* %9
%86 = mul nsw i32 %84, %85
%87 = load i32, i32* %9
%88 = add nsw i32 %86, %87
store i32 %88, i32* %10
%89 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 %88)
%90 = load i32, i32* %9
%91 = add nsw i32 %90, 1
store i32 %91, i32* %9
br label %79
92: ; preds = %79
%93 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.5, i64 0, i64 0))
%94 = call i32 (...) @getchar()
store i32 3, i32* %11
store i32 4, i32* %12
store i32 7, i32* %13
%95 = load i32, i32* %11
%96 = load i32, i32* %12
%97 = srem i32 %95, %96
%98 = load i32, i32* %13
%99 = load i32, i32* %11
%100 = sdiv i32 %98, %99
%101 = sub nsw i32 %100, 1
%102 = load i32, i32* %12
%103 = mul nsw i32 %101, %102
%104 = sdiv i32 %97, %103
%105 = sub nsw i32 %104, 1
store i32 %105, i32* %14
%106 = load i32, i32* %14
%107 = add nsw i32 %106, 1
%108 = icmp ne i32 %107, 0
br i1 %108, label %109, label %111
109: ; preds = %92
%110 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0))
br label %113
111: ; preds = %92
%112 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.7, i64 0, i64 0))
br label %113
113: ; preds = %111, %109
%114 = call i32 (...) @getchar()
store i32 11, i32* %15
store i32 4, i32* %16
store i32 6, i32* %17
store i32 3, i32* %18
store i32 2, i32* %19
%115 = load i32, i32* %18
%116 = load i32, i32* %15
%117 = load i32, i32* %17
%118 = add nsw i32 %117, 1
store i32 %118, i32* %17
%119 = srem i32 %116, %117
%120 = mul nsw i32 %115, %119
%121 = load i32, i32* %15
%122 = load i32, i32* %16
%123 = sdiv i32 %121, %122
%124 = sub nsw i32 %120, %123
%125 = sub nsw i32 %124, 1
store i32 %125, i32* %20
%126 = load i32, i32* %15
%127 = add nsw i32 %126, 1
store i32 %127, i32* %15
%128 = load i32, i32* %17
%129 = mul nsw i32 %127, %128
%130 = load i32, i32* %19
%131 = add nsw i32 %130, -1
store i32 %131, i32* %19
%132 = srem i32 %129, %131
%133 = add nsw i32 %132, 1
store i32 %133, i32* %21
%134 = load i32, i32* %15
%135 = load i32, i32* %17
%136 = load i32, i32* %18
%137 = add nsw i32 %136, -1
store i32 %137, i32* %18
%138 = sdiv i32 %135, %136
%139 = mul nsw i32 %134, %138
%140 = sitofp i32 %139 to float
store float %140, float* %23
store float %140, float* %22
%141 = load float, float* %23
%142 = load i32, i32* %15
%143 = load i32, i32* %18
%144 = sdiv i32 %142, %143
%145 = sitofp i32 %144 to float
%146 = fsub float %141, %145
store float %146, float* %23
%147 = load i32, i32* %20
%148 = load i32, i32* %21
%149 = load float, float* %22
%150 = fpext float %149 to double
%151 = load float, float* %23
%152 = fpext float %151 to double
%153 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.8, i64 0, i64 0), i32 %147, i32 %148, double %150, double %152)
%154 = call i32 (...) @getchar()
%155 = load i32, i32* %1
ret i32 %155
}

LLVM IR (-O2):
@.str = [5 x i8] c"%d,\0A\00"
@.str.1 = [4 x i8] c"%d\0A\00"
@.str.2 = [7 x i8] c"%.1f\0A \00"
@.str.3 = [13 x i8] c"%d %d %d %d\0A\00"
@.str.4 = [4 x i8] c"%d \00"
@.str.8 = [29 x i8] c"f = %d g = %d i = %f j = %f\0A\00"
@str = [5 x i8] c"MIKO\00"
define i32 @main() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 2)
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 4)
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 7)
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 11)
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 2)
%6 = tail call i32 (...) @getchar()
%7 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i64 2)
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.2, i64 0, i64 0), double 2.750000e+00)
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), double 2.750000e+00)
%10 = tail call i32 (...) @getchar()
%11 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0), i32 5, i32 2, i32 4, i32 25)
%12 = tail call i32 (...) @getchar()
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 0)
%14 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 2)
%15 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i32 8)
%16 = tail call i32 @putchar(i32 10)
%17 = tail call i32 (...) @getchar()
%18 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str, i64 0, i64 0))
%19 = tail call i32 (...) @getchar()
%20 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @.str.8, i64 0, i64 0), i32 12, i32 1, double 2.400000e+01, double 1.800000e+01)
%21 = tail call i32 (...) @getchar()
ret i32 0
}