#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 absVal(double);
int /*<<< orphan*/ asort(int *, int);
int /*<<< orphan*/ calculateTriangularNumber(int);
int /*<<< orphan*/ gcd(int, int);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, int *);
double squareRoot(double);
int main() {
  calculateTriangularNumber(10);
  calculateTriangularNumber(20);
  calculateTriangularNumber(50);
  gcd(150, 35);
  gcd(126, 405);
  gcd(83, 240);
  float f1 = -15.5, f2 = 20.0, f3 = -5.0;
  int i1 = -716;
  float result;
  result = absVal(f1);
  printf("result = %.2f\n", result);
  printf("f1 = %.2f\n", f1);
  result = absVal(f2);
  printf("result = %.2f\n", result);
  printf("f2 = %.2f\n", f2);
  result = absVal((float)i1);
  printf("result = %.2f\n", result);
  printf("i1 = %i\n", i1);
  printf("\nNow we'll pass -6.0/4 to absVal inside the printf call itself\n");
  printf("%.2f\n", absVal(-6.0) / 4);
  printf("squareRoot(2.0) = %f\n", squareRoot(2.0));
  printf("squareRoot(144.0) = %f\n", squareRoot(144.0));
  printf("squareRoot(17.5) = %f\n", squareRoot(17.5));
  printf("\nNow we'll test our minimum() function which takes the entire array "
         "as an argument\n");
  int scores[10], i, minScore;
  int numScores;
  int minimum(int values[], int nelms);
  printf("How many scores would you like to enter? ");
  scanf("%i", &numScores);
  printf("Enter %i scores: \n", numScores);
  for (i = 0; i < numScores; ++i) {
    scanf("%i", &scores[i]);
  }
  minScore = minimum(scores, numScores);
  printf("\nMinimum score is %i\n", minScore);
  printf("Now lets sort the scores[] array in ascending order...\n\n");
  asort(scores, numScores);
  for (i = 0; i < numScores; ++i) {
    printf("scores[%i] = %i\n", i, scores[i]);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0xa,%edi
call   1050 <calculateTriangularNumber@plt>
mov    $0x14,%edi
call   1050 <calculateTriangularNumber@plt>
mov    $0x32,%edi
call   1050 <calculateTriangularNumber@plt>
mov    $0x96,%edi
mov    $0x23,%esi
call   10a0 <gcd@plt>
mov    $0x7e,%edi
mov    $0x195,%esi
call   10a0 <gcd@plt>
mov    $0x53,%edi
mov    $0xf0,%esi
call   10a0 <gcd@plt>
movss  0xe46(%rip),%xmm0
movss  %xmm0,-0x8(%rbp)
movss  0xe35(%rip),%xmm0
movss  %xmm0,-0xc(%rbp)
movss  0xe24(%rip),%xmm0
movss  %xmm0,-0x10(%rbp)
movl   $0xfffffd34,-0x14(%rbp)
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
call   1070 <absVal@plt>
cvtsi2ss %eax,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x18(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xdfd(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xdf5(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
call   1070 <absVal@plt>
cvtsi2ss %eax,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x18(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xdb8(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movss  -0xc(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xdbb(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
cvtsi2ssl -0x14(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
call   1070 <absVal@plt>
cvtsi2ss %eax,%xmm0
movss  %xmm0,-0x18(%rbp)
movss  -0x18(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xd73(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
mov    -0x14(%rbp),%esi
lea    0xd87(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xd82(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movsd  0xd31(%rip),%xmm0
call   1070 <absVal@plt>
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    %eax,%esi
lea    0xd43(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movsd  0xd04(%rip),%xmm0
call   1090 <squareRoot@plt>
lea    0xd82(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movsd  0xce1(%rip),%xmm0
call   1090 <squareRoot@plt>
lea    0xd7d(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movsd  0xcbe(%rip),%xmm0
call   1090 <squareRoot@plt>
lea    0xd7a(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
lea    0xd83(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xdc9(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xde5(%rip),%rdi
lea    -0x4c(%rbp),%rsi
call   1080 <scanf@plt>
mov    -0x4c(%rbp),%esi
lea    0xdd5(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movl   $0x0,-0x44(%rbp)
mov    -0x44(%rbp),%eax
cmp    -0x4c(%rbp),%eax
jge    13ce <main+0x24e>
movslq -0x44(%rbp),%rax
lea    -0x40(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xda2(%rip),%rdi
call   1080 <scanf@plt>
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1399 <main+0x219>
lea    -0x40(%rbp),%rdi
mov    -0x4c(%rbp),%esi
call   1030 <minimum@plt>
mov    %eax,-0x48(%rbp)
mov    -0x48(%rbp),%esi
lea    0xd8c(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xd94(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    -0x40(%rbp),%rdi
mov    -0x4c(%rbp),%esi
call   1060 <asort@plt>
movl   $0x0,-0x44(%rbp)
mov    -0x44(%rbp),%eax
cmp    -0x4c(%rbp),%eax
jge    1442 <main+0x2c2>
mov    -0x44(%rbp),%esi
movslq -0x44(%rbp),%rax
mov    -0x40(%rbp,%rax,4),%edx
lea    0xd95(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    140f <main+0x28f>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %rbx
sub    $0x40,%rsp
mov    $0xa,%edi
call   1060 <calculateTriangularNumber@plt>
mov    $0x14,%edi
call   1060 <calculateTriangularNumber@plt>
mov    $0x32,%edi
call   1060 <calculateTriangularNumber@plt>
mov    $0x96,%edi
mov    $0x23,%esi
call   10b0 <gcd@plt>
mov    $0x7e,%edi
mov    $0x195,%esi
call   10b0 <gcd@plt>
mov    $0x53,%edi
mov    $0xf0,%esi
call   10b0 <gcd@plt>
movsd  0xe14(%rip),%xmm0
call   1080 <absVal@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xe35(%rip),%rbx
mov    %rbx,%rdi
mov    $0x1,%al
call   1050 <printf@plt>
lea    0xe33(%rip),%rdi
movsd  0xde4(%rip),%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
movsd  0xddd(%rip),%xmm0
call   1080 <absVal@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
cvtss2sd %xmm0,%xmm0
mov    %rbx,%rdi
mov    $0x1,%al
call   1050 <printf@plt>
lea    0xe06(%rip),%rdi
movsd  0xdb4(%rip),%xmm0
mov    $0x1,%al
call   1050 <printf@plt>
movsd  0xdad(%rip),%xmm0
call   1080 <absVal@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
cvtss2sd %xmm0,%xmm0
mov    %rbx,%rdi
mov    $0x1,%al
call   1050 <printf@plt>
lea    0xdd9(%rip),%rdi
mov    $0xfffffd34,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xe7b(%rip),%rdi
call   1030 <puts@plt>
movsd  0xd74(%rip),%xmm0
call   1080 <absVal@plt>
lea    0x3(%rax),%esi
test   %eax,%eax
cmovns %eax,%esi
sar    $0x2,%esi
lea    0xd91(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
movsd  0xd56(%rip),%xmm0
call   10a0 <squareRoot@plt>
lea    0xd90(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
movsd  0xd43(%rip),%xmm0
call   10a0 <squareRoot@plt>
lea    0xd8b(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
movsd  0xd30(%rip),%xmm0
call   10a0 <squareRoot@plt>
lea    0xd88(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
lea    0xe37(%rip),%rdi
call   1030 <puts@plt>
lea    0xd85(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xda1(%rip),%rdi
lea    0xc(%rsp),%rsi
call   1090 <scanf@plt>
mov    0xc(%rsp),%esi
lea    0xd8f(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0xc(%rsp),%esi
test   %esi,%esi
jle    138d <main+0x1fd>
lea    0x10(%rsp),%r15
xor    %ebx,%ebx
lea    0xd6f(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    %r15,%rsi
call   1090 <scanf@plt>
add    $0x1,%rbx
movslq 0xc(%rsp),%rsi
add    $0x4,%r15
cmp    %rsi,%rbx
jl     1370 <main+0x1e0>
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <minimum@plt>
lea    0xd4a(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xdf3(%rip),%rdi
call   1030 <puts@plt>
mov    0xc(%rsp),%esi
mov    %rbx,%rdi
call   1070 <asort@plt>
cmpl   $0x0,0xc(%rsp)
jle    13fe <main+0x26e>
lea    0xd31(%rip),%r14
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    0x10(%rsp,%rbx,4),%edx
mov    %r14,%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%rbx
movslq 0xc(%rsp),%rax
cmp    %rax,%rbx
jl     13e0 <main+0x250>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [15 x i8] c"result = %.2f\0A\00"
@.str.1 = [11 x i8] c"f1 = %.2f\0A\00"
@.str.2 = [11 x i8] c"f2 = %.2f\0A\00"
@.str.3 = [9 x i8] c"i1 = %i\0A\00"
@.str.4 = [64 x i8] c"\0ANow we'll pass -6.0/4 to absVal inside the printf call itself\0A\00"
@.str.5 = [6 x i8] c"%.2f\0A\00"
@.str.6 = [22 x i8] c"squareRoot(2.0) = %f\0A\00"
@.str.7 = [24 x i8] c"squareRoot(144.0) = %f\0A\00"
@.str.8 = [23 x i8] c"squareRoot(17.5) = %f\0A\00"
@.str.9 = [84 x i8] c"\0ANow we'll test our minimum() function which takes the entire array as an argument\0A\00"
@.str.10 = [42 x i8] c"How many scores would you like to enter? \00"
@.str.11 = [3 x i8] c"%i\00"
@.str.12 = [19 x i8] c"Enter %i scores: \0A\00"
@.str.13 = [22 x i8] c"\0AMinimum score is %i\0A\00"
@.str.14 = [57 x i8] c"Now lets sort the scores[] array in ascending order...\0A\0A\00"
@.str.15 = [17 x i8] c"scores[%i] = %i\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca i32
%6 = alloca float
%7 = alloca [10 x i32]
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32 0, i32* %1
%11 = call i32 @calculateTriangularNumber(i32 10)
%12 = call i32 @calculateTriangularNumber(i32 20)
%13 = call i32 @calculateTriangularNumber(i32 50)
%14 = call i32 @gcd(i32 150, i32 35)
%15 = call i32 @gcd(i32 126, i32 405)
%16 = call i32 @gcd(i32 83, i32 240)
store float -1.550000e+01, float* %2
store float 2.000000e+01, float* %3
store float -5.000000e+00, float* %4
store i32 -716, i32* %5
%17 = load float, float* %2
%18 = fpext float %17 to double
%19 = call i32 @absVal(double %18)
%20 = sitofp i32 %19 to float
store float %20, float* %6
%21 = load float, float* %6
%22 = fpext float %21 to double
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), double %22)
%24 = load float, float* %2
%25 = fpext float %24 to double
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), double %25)
%27 = load float, float* %3
%28 = fpext float %27 to double
%29 = call i32 @absVal(double %28)
%30 = sitofp i32 %29 to float
store float %30, float* %6
%31 = load float, float* %6
%32 = fpext float %31 to double
%33 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), double %32)
%34 = load float, float* %3
%35 = fpext float %34 to double
%36 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0), double %35)
%37 = load i32, i32* %5
%38 = sitofp i32 %37 to float
%39 = fpext float %38 to double
%40 = call i32 @absVal(double %39)
%41 = sitofp i32 %40 to float
store float %41, float* %6
%42 = load float, float* %6
%43 = fpext float %42 to double
%44 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), double %43)
%45 = load i32, i32* %5
%46 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0), i32 %45)
%47 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.4, i64 0, i64 0))
%48 = call i32 @absVal(double -6.000000e+00)
%49 = sdiv i32 %48, 4
%50 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0), i32 %49)
%51 = call double @squareRoot(double 2.000000e+00)
%52 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.6, i64 0, i64 0), double %51)
%53 = call double @squareRoot(double 1.440000e+02)
%54 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.7, i64 0, i64 0), double %53)
%55 = call double @squareRoot(double 1.750000e+01)
%56 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.8, i64 0, i64 0), double %55)
%57 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([84 x i8], [84 x i8]* @.str.9, i64 0, i64 0))
%58 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.10, i64 0, i64 0))
%59 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.11, i64 0, i64 0), i32* %10)
%60 = load i32, i32* %10
%61 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.12, i64 0, i64 0), i32 %60)
store i32 0, i32* %8
br label %62
62: ; preds = %71, %0
%63 = load i32, i32* %8
%64 = load i32, i32* %10
%65 = icmp slt i32 %63, %64
br i1 %65, label %66, label %74
66: ; preds = %62
%67 = load i32, i32* %8
%68 = sext i32 %67 to i64
%69 = getelementptr inbounds [10 x i32], [10 x i32]* %7, i64 0, i64 %68
%70 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.11, i64 0, i64 0), i32* %69)
br label %71
71: ; preds = %66
%72 = load i32, i32* %8
%73 = add nsw i32 %72, 1
store i32 %73, i32* %8
br label %62
74: ; preds = %62
%75 = getelementptr inbounds [10 x i32], [10 x i32]* %7, i64 0, i64 0
%76 = load i32, i32* %10
%77 = call i32 @minimum(i32* %75, i32 %76)
store i32 %77, i32* %9
%78 = load i32, i32* %9
%79 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.13, i64 0, i64 0), i32 %78)
%80 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.14, i64 0, i64 0))
%81 = getelementptr inbounds [10 x i32], [10 x i32]* %7, i64 0, i64 0
%82 = load i32, i32* %10
%83 = call i32 @asort(i32* %81, i32 %82)
store i32 0, i32* %8
br label %84
84: ; preds = %95, %74
%85 = load i32, i32* %8
%86 = load i32, i32* %10
%87 = icmp slt i32 %85, %86
br i1 %87, label %88, label %98
88: ; preds = %84
%89 = load i32, i32* %8
%90 = load i32, i32* %8
%91 = sext i32 %90 to i64
%92 = getelementptr inbounds [10 x i32], [10 x i32]* %7, i64 0, i64 %91
%93 = load i32, i32* %92
%94 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0), i32 %89, i32 %93)
br label %95
95: ; preds = %88
%96 = load i32, i32* %8
%97 = add nsw i32 %96, 1
store i32 %97, i32* %8
br label %84
98: ; preds = %84
ret i32 0
}

LLVM IR (-O2):
@.str = [15 x i8] c"result = %.2f\0A\00"
@.str.1 = [11 x i8] c"f1 = %.2f\0A\00"
@.str.2 = [11 x i8] c"f2 = %.2f\0A\00"
@.str.3 = [9 x i8] c"i1 = %i\0A\00"
@.str.5 = [6 x i8] c"%.2f\0A\00"
@.str.6 = [22 x i8] c"squareRoot(2.0) = %f\0A\00"
@.str.7 = [24 x i8] c"squareRoot(144.0) = %f\0A\00"
@.str.8 = [23 x i8] c"squareRoot(17.5) = %f\0A\00"
@.str.10 = [42 x i8] c"How many scores would you like to enter? \00"
@.str.11 = [3 x i8] c"%i\00"
@.str.12 = [19 x i8] c"Enter %i scores: \0A\00"
@.str.13 = [22 x i8] c"\0AMinimum score is %i\0A\00"
@.str.15 = [17 x i8] c"scores[%i] = %i\0A\00"
@str = [63 x i8] c"\0ANow we'll pass -6.0/4 to absVal inside the printf call itself\00"
@str.16 = [83 x i8] c"\0ANow we'll test our minimum() function which takes the entire array as an argument\00"
@str.17 = [56 x i8] c"Now lets sort the scores[] array in ascending order...\0A\00"
define i32 @main() {
%1 = alloca [10 x i32]
%2 = alloca i32
%3 = tail call i32 @calculateTriangularNumber(i32 10)
%4 = tail call i32 @calculateTriangularNumber(i32 20)
%5 = tail call i32 @calculateTriangularNumber(i32 50)
%6 = tail call i32 @gcd(i32 150, i32 35)
%7 = tail call i32 @gcd(i32 126, i32 405)
%8 = tail call i32 @gcd(i32 83, i32 240)
%9 = tail call i32 @absVal(double -1.550000e+01)
%10 = sitofp i32 %9 to float
%11 = fpext float %10 to double
%12 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), double %11)
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0), double -1.550000e+01)
%14 = tail call i32 @absVal(double 2.000000e+01)
%15 = sitofp i32 %14 to float
%16 = fpext float %15 to double
%17 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), double %16)
%18 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0), double 2.000000e+01)
%19 = tail call i32 @absVal(double -7.160000e+02)
%20 = sitofp i32 %19 to float
%21 = fpext float %20 to double
%22 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), double %21)
%23 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0), i32 -716)
%24 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([63 x i8], [63 x i8]* @str, i64 0, i64 0))
%25 = tail call i32 @absVal(double -6.000000e+00)
%26 = sdiv i32 %25, 4
%27 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.5, i64 0, i64 0), i32 %26)
%28 = tail call double @squareRoot(double 2.000000e+00)
%29 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.6, i64 0, i64 0), double %28)
%30 = tail call double @squareRoot(double 1.440000e+02)
%31 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @.str.7, i64 0, i64 0), double %30)
%32 = tail call double @squareRoot(double 1.750000e+01)
%33 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.8, i64 0, i64 0), double %32)
%34 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([83 x i8], [83 x i8]* @str.16, i64 0, i64 0))
%35 = bitcast [10 x i32]* %1 to i8*
%36 = bitcast i32* %2 to i8*
%37 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @.str.10, i64 0, i64 0))
%38 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.11, i64 0, i64 0), i32* %2)
%39 = load i32, i32* %2
%40 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.12, i64 0, i64 0), i32 %39)
%41 = load i32, i32* %2
%42 = icmp sgt i32 %41, 0
br i1 %42, label %43, label %51
43: ; preds = %0, %43
%44 = phi i64 [ %47, %43 ], [ 0, %0 ]
%45 = getelementptr inbounds [10 x i32], [10 x i32]* %1, i64 0, i64 %44
%46 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.11, i64 0, i64 0), i32* %45)
%47 = add nuw nsw i64 %44, 1
%48 = load i32, i32* %2
%49 = sext i32 %48 to i64
%50 = icmp slt i64 %47, %49
br i1 %50, label %43, label %51
51: ; preds = %43, %0
%52 = phi i32 [ %41, %0 ], [ %48, %43 ]
%53 = getelementptr inbounds [10 x i32], [10 x i32]* %1, i64 0, i64 0
%54 = call i32 @minimum(i32* %53, i32 %52)
%55 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.13, i64 0, i64 0), i32 %54)
%56 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([56 x i8], [56 x i8]* @str.17, i64 0, i64 0))
%57 = load i32, i32* %2
%58 = call i32 @asort(i32* %53, i32 %57)
%59 = load i32, i32* %2
%60 = icmp sgt i32 %59, 0
br i1 %60, label %61, label %71
61: ; preds = %51, %61
%62 = phi i64 [ %67, %61 ], [ 0, %51 ]
%63 = getelementptr inbounds [10 x i32], [10 x i32]* %1, i64 0, i64 %62
%64 = load i32, i32* %63
%65 = trunc i64 %62 to i32
%66 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0), i32 %65, i32 %64)
%67 = add nuw nsw i64 %62, 1
%68 = load i32, i32* %2
%69 = sext i32 %68 to i64
%70 = icmp slt i64 %67, %69
br i1 %70, label %61, label %71
71: ; preds = %61, %51
ret i32 0
}