#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*/ accept(int *, unsigned int *);
int *binsrch(int, int *, unsigned int);
int /*<<< orphan*/ display(int *, unsigned int);
int /*<<< orphan*/ isort(int *, unsigned int);
int *linsrch(int *, unsigned int, int);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ putchar(char);
int /*<<< orphan*/ puts(char *);
int /*<<< orphan*/ scanf(char *, ...);
int main() {
  unsigned i, n, ch;
  int a[50], key, *res, mul_pos[50];
  n = 0;
  do {
    puts("What would you like to do?");
    puts(" ( 0) Exit");
    puts(" ( 1) Populate Array");
    puts(" ( 2) Print Array");
    puts(" ( 3) Linear Search");
    puts(" ( 4) Sort");
    puts(" ( 5) Binary Search");
    scanf(" %u%*c", &ch);
    switch (ch) {
    case 0:
      puts("Bye!");
      break;
    case 1:
      accept(a, &n);
      break;
    case 2:
      display(a, n);
      break;
    case 3:
      puts("Key?");
      scanf(" %d%*c", &key);
      for (i = 0, res = a - 1; (res = linsrch(res + 1, n, key)); ++i)
        mul_pos[i] = res - a + 1;
      if (res == a)
        puts("Not found.");
      else {
        printf("Found at position(s): ");
        display(mul_pos, i);
      }
      break;
    case 4:
      isort(a, n);
      break;
    case 5:
      puts("Key?");
      scanf(" %d%*c", &key);
      if ((res = binsrch(key, a, n)))
        printf("Found at position: %lld\n", (long long int)(res - a + 1));
      else
        puts("Not found.");
      break;
    default:
      puts("Incorrect Choice!");
      break;
    }
  } while (ch);
  putchar('\n');
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1d0,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0xc(%rbp)
lea    0xe68(%rip),%rdi
call   1040 <puts@plt>
lea    0xe77(%rip),%rdi
call   1040 <puts@plt>
lea    0xe76(%rip),%rdi
call   1040 <puts@plt>
lea    0xe7f(%rip),%rdi
call   1040 <puts@plt>
lea    0xe85(%rip),%rdi
call   1040 <puts@plt>
lea    0xe8d(%rip),%rdi
call   1040 <puts@plt>
lea    0xe8c(%rip),%rdi
call   1040 <puts@plt>
lea    0xe94(%rip),%rdi
xor    %eax,%eax
lea    -0x10(%rbp),%rsi
call   10a0 <scanf@plt>
mov    -0x10(%rbp),%eax
mov    %rax,-0x1c8(%rbp)
sub    $0x5,%rax
ja     13ed <main+0x25d>
mov    -0x1c8(%rbp),%rax
lea    0xdcf(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xe5e(%rip),%rdi
call   1040 <puts@plt>
jmp    13f9 <main+0x269>
lea    -0xe0(%rbp),%rdi
lea    -0xc(%rbp),%rsi
call   10b0 <accept@plt>
jmp    13f9 <main+0x269>
lea    -0xe0(%rbp),%rdi
mov    -0xc(%rbp),%esi
call   1050 <display@plt>
jmp    13f9 <main+0x269>
lea    0xe29(%rip),%rdi
call   1040 <puts@plt>
lea    0xe22(%rip),%rdi
lea    -0xe4(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
movl   $0x0,-0x8(%rbp)
lea    -0xe0(%rbp),%rax
add    $0xfffffffffffffffc,%rax
mov    %rax,-0xf0(%rbp)
mov    -0xf0(%rbp),%rdi
add    $0x4,%rdi
mov    -0xc(%rbp),%esi
mov    -0xe4(%rbp),%edx
call   1090 <linsrch@plt>
mov    %rax,-0xf0(%rbp)
cmp    $0x0,%rax
je     130b <main+0x17b>
mov    -0xf0(%rbp),%rax
lea    -0xe0(%rbp),%rcx
sub    %rcx,%rax
sar    $0x2,%rax
add    $0x1,%rax
mov    %eax,%ecx
mov    -0x8(%rbp),%eax
mov    %ecx,-0x1c0(%rbp,%rax,4)
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    12ae <main+0x11e>
mov    -0xf0(%rbp),%rax
lea    -0xe0(%rbp),%rcx
cmp    %rcx,%rax
jne    1333 <main+0x1a3>
lea    0xd87(%rip),%rdi
call   1040 <puts@plt>
jmp    1350 <main+0x1c0>
lea    0xd81(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0x1c0(%rbp),%rdi
mov    -0x8(%rbp),%esi
call   1050 <display@plt>
jmp    13f9 <main+0x269>
lea    -0xe0(%rbp),%rdi
mov    -0xc(%rbp),%esi
call   1080 <isort@plt>
jmp    13f9 <main+0x269>
lea    0xd34(%rip),%rdi
call   1040 <puts@plt>
lea    0xd2d(%rip),%rdi
lea    -0xe4(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0xe4(%rbp),%edi
lea    -0xe0(%rbp),%rsi
mov    -0xc(%rbp),%edx
call   1070 <binsrch@plt>
mov    %rax,-0xf0(%rbp)
cmp    $0x0,%rax
je     13dc <main+0x24c>
mov    -0xf0(%rbp),%rsi
lea    -0xe0(%rbp),%rax
sub    %rax,%rsi
sar    $0x2,%rsi
add    $0x1,%rsi
lea    0xd02(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    13e8 <main+0x258>
lea    0xccd(%rip),%rdi
call   1040 <puts@plt>
jmp    13f9 <main+0x269>
lea    0xcf7(%rip),%rdi
call   1040 <puts@plt>
jmp    13fe <main+0x26e>
cmpl   $0x0,-0x10(%rbp)
jne    11a9 <main+0x19>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
add    $0x1d0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x1a8,%rsp
movl   $0x0,0x4(%rsp)
lea    0xe68(%rip),%r14
lea    0xe7c(%rip),%r12
lea    0xe80(%rip),%rbx
lea    0xe8e(%rip),%rbp
lea    0xe34(%rip),%r15
lea    0xe0(%rsp),%r13
jmp    11ed <main+0x5d>
lea    0xf0e(%rip),%rdi
call   1040 <puts@plt>
cmpl   $0x0,0xc(%rsp)
je     138e <main+0x1fe>
mov    %r14,%rdi
call   1040 <puts@plt>
mov    %r12,%rdi
call   1040 <puts@plt>
mov    %rbx,%rdi
call   1040 <puts@plt>
mov    %rbp,%rdi
call   1040 <puts@plt>
lea    0xe51(%rip),%rdi
call   1040 <puts@plt>
lea    0xe59(%rip),%rdi
call   1040 <puts@plt>
lea    0xe58(%rip),%rdi
call   1040 <puts@plt>
lea    0xe60(%rip),%rdi
lea    0xc(%rsp),%rsi
xor    %eax,%eax
call   10a0 <scanf@plt>
mov    0xc(%rsp),%eax
cmp    $0x5,%rax
ja     11d6 <main+0x46>
movslq (%r15,%rax,4),%rax
add    %r15,%rax
jmp    *%rax
lea    0xe41(%rip),%rdi
jmp    11dd <main+0x4d>
mov    %r13,%rdi
lea    0x4(%rsp),%rsi
call   10b0 <accept@plt>
jmp    11e2 <main+0x52>
mov    0x4(%rsp),%esi
mov    %r13,%rdi
call   1050 <display@plt>
jmp    11e2 <main+0x52>
lea    0xe17(%rip),%rdi
call   1040 <puts@plt>
xor    %ebx,%ebx
lea    0xe0e(%rip),%rdi
lea    0x8(%rsp),%rsi
xor    %eax,%eax
call   10a0 <scanf@plt>
mov    0x4(%rsp),%esi
mov    0x8(%rsp),%edx
mov    %r13,%rdi
call   1090 <linsrch@plt>
test   %rax,%rax
je     12ef <main+0x15f>
xor    %ebx,%ebx
xchg   %ax,%ax
mov    %rax,%rcx
sub    %r13,%rcx
shr    $0x2,%rcx
add    $0x1,%ecx
mov    %ebx,%edx
mov    %ecx,0x10(%rsp,%rdx,4)
add    $0x1,%ebx
add    $0x4,%rax
mov    0x4(%rsp),%esi
mov    0x8(%rsp),%edx
mov    %rax,%rdi
call   1090 <linsrch@plt>
test   %rax,%rax
jne    12c0 <main+0x130>
lea    0xdc5(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
lea    0x10(%rsp),%rdi
mov    %ebx,%esi
call   1050 <display@plt>
lea    0xd2e(%rip),%rbx
lea    0xd3c(%rip),%rbp
jmp    11e2 <main+0x52>
mov    0x4(%rsp),%esi
mov    %r13,%rdi
call   1080 <isort@plt>
jmp    11e2 <main+0x52>
lea    0xd70(%rip),%rdi
call   1040 <puts@plt>
lea    0xd69(%rip),%rdi
lea    0x8(%rsp),%rsi
xor    %eax,%eax
call   10a0 <scanf@plt>
mov    0x8(%rsp),%edi
mov    0x4(%rsp),%edx
mov    %r13,%rsi
call   1070 <binsrch@plt>
test   %rax,%rax
je     1382 <main+0x1f2>
sub    %r13,%rax
sar    $0x2,%rax
add    $0x1,%rax
lea    0xd5f(%rip),%rdi
mov    %rax,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
jmp    11e2 <main+0x52>
lea    0xd27(%rip),%rdi
jmp    11dd <main+0x4d>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
add    $0x1a8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [27 x i8] c"What would you like to do?\00"
@.str.1 = [11 x i8] c" ( 0) Exit\00"
@.str.2 = [21 x i8] c" ( 1) Populate Array\00"
@.str.3 = [18 x i8] c" ( 2) Print Array\00"
@.str.4 = [20 x i8] c" ( 3) Linear Search\00"
@.str.5 = [11 x i8] c" ( 4) Sort\00"
@.str.6 = [20 x i8] c" ( 5) Binary Search\00"
@.str.7 = [7 x i8] c" %u%*c\00"
@.str.8 = [5 x i8] c"Bye!\00"
@.str.9 = [5 x i8] c"Key?\00"
@.str.10 = [7 x i8] c" %d%*c\00"
@.str.11 = [11 x i8] c"Not found.\00"
@.str.12 = [23 x i8] c"Found at position(s): \00"
@.str.13 = [25 x i8] c"Found at position: %lld\0A\00"
@.str.14 = [18 x i8] c"Incorrect Choice!\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca [50 x i32]
%6 = alloca i32
%7 = alloca i32*
%8 = alloca [50 x i32]
store i32 0, i32* %1
store i32 0, i32* %3
br label %9
9: ; preds = %94, %0
%10 = call i32 @puts(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0))
%11 = call i32 @puts(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
%12 = call i32 @puts(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.2, i64 0, i64 0))
%13 = call i32 @puts(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0))
%14 = call i32 @puts(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0))
%15 = call i32 @puts(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.5, i64 0, i64 0))
%16 = call i32 @puts(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.6, i64 0, i64 0))
%17 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i64 0, i64 0), i32* %4)
%18 = load i32, i32* %4
switch i32 %18, label %91 [
i32 0, label %19
i32 1, label %21
i32 2, label %24
i32 3, label %28
i32 4, label %67
i32 5, label %71
]
19: ; preds = %9
%20 = call i32 @puts(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0))
br label %93
21: ; preds = %9
%22 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%23 = call i32 @accept(i32* %22, i32* %3)
br label %93
24: ; preds = %9
%25 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%26 = load i32, i32* %3
%27 = call i32 @display(i32* %25, i32 %26)
br label %93
28: ; preds = %9
%29 = call i32 @puts(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0))
%30 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.10, i64 0, i64 0), i32* %6)
store i32 0, i32* %2
%31 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%32 = getelementptr inbounds i32, i32* %31, i64 -1
store i32* %32, i32** %7
br label %33
33: ; preds = %52, %28
%34 = load i32*, i32** %7
%35 = getelementptr inbounds i32, i32* %34, i64 1
%36 = load i32, i32* %3
%37 = load i32, i32* %6
%38 = call i32* @linsrch(i32* %35, i32 %36, i32 %37)
store i32* %38, i32** %7
%39 = icmp ne i32* %38, null
br i1 %39, label %40, label %55
40: ; preds = %33
%41 = load i32*, i32** %7
%42 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%43 = ptrtoint i32* %41 to i64
%44 = ptrtoint i32* %42 to i64
%45 = sub i64 %43, %44
%46 = sdiv exact i64 %45, 4
%47 = add nsw i64 %46, 1
%48 = trunc i64 %47 to i32
%49 = load i32, i32* %2
%50 = zext i32 %49 to i64
%51 = getelementptr inbounds [50 x i32], [50 x i32]* %8, i64 0, i64 %50
store i32 %48, i32* %51
br label %52
52: ; preds = %40
%53 = load i32, i32* %2
%54 = add i32 %53, 1
store i32 %54, i32* %2
br label %33
55: ; preds = %33
%56 = load i32*, i32** %7
%57 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%58 = icmp eq i32* %56, %57
br i1 %58, label %59, label %61
59: ; preds = %55
%60 = call i32 @puts(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.11, i64 0, i64 0))
br label %66
61: ; preds = %55
%62 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.12, i64 0, i64 0))
%63 = getelementptr inbounds [50 x i32], [50 x i32]* %8, i64 0, i64 0
%64 = load i32, i32* %2
%65 = call i32 @display(i32* %63, i32 %64)
br label %66
66: ; preds = %61, %59
br label %93
67: ; preds = %9
%68 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%69 = load i32, i32* %3
%70 = call i32 @isort(i32* %68, i32 %69)
br label %93
71: ; preds = %9
%72 = call i32 @puts(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0))
%73 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.10, i64 0, i64 0), i32* %6)
%74 = load i32, i32* %6
%75 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%76 = load i32, i32* %3
%77 = call i32* @binsrch(i32 %74, i32* %75, i32 %76)
store i32* %77, i32** %7
%78 = icmp ne i32* %77, null
br i1 %78, label %79, label %88
79: ; preds = %71
%80 = load i32*, i32** %7
%81 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
%82 = ptrtoint i32* %80 to i64
%83 = ptrtoint i32* %81 to i64
%84 = sub i64 %82, %83
%85 = sdiv exact i64 %84, 4
%86 = add nsw i64 %85, 1
%87 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.13, i64 0, i64 0), i64 %86)
br label %90
88: ; preds = %71
%89 = call i32 @puts(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.11, i64 0, i64 0))
br label %90
90: ; preds = %88, %79
br label %93
91: ; preds = %9
%92 = call i32 @puts(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.14, i64 0, i64 0))
br label %93
93: ; preds = %91, %90, %67, %66, %24, %21, %19
br label %94
94: ; preds = %93
%95 = load i32, i32* %4
%96 = icmp ne i32 %95, 0
br i1 %96, label %9, label %97
97: ; preds = %94
%98 = call i32 @putchar(i8 signext 10)
ret i32 0
}

LLVM IR (-O2):
@.str = [27 x i8] c"What would you like to do?\00"
@.str.1 = [11 x i8] c" ( 0) Exit\00"
@.str.2 = [21 x i8] c" ( 1) Populate Array\00"
@.str.3 = [18 x i8] c" ( 2) Print Array\00"
@.str.4 = [20 x i8] c" ( 3) Linear Search\00"
@.str.5 = [11 x i8] c" ( 4) Sort\00"
@.str.6 = [20 x i8] c" ( 5) Binary Search\00"
@.str.7 = [7 x i8] c" %u%*c\00"
@.str.8 = [5 x i8] c"Bye!\00"
@.str.9 = [5 x i8] c"Key?\00"
@.str.10 = [7 x i8] c" %d%*c\00"
@.str.11 = [11 x i8] c"Not found.\00"
@.str.12 = [23 x i8] c"Found at position(s): \00"
@.str.13 = [25 x i8] c"Found at position: %lld\0A\00"
@.str.14 = [18 x i8] c"Incorrect Choice!\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [50 x i32]
%4 = alloca i32
%5 = alloca [50 x i32]
%6 = bitcast i32* %1 to i8*
%7 = bitcast i32* %2 to i8*
%8 = bitcast [50 x i32]* %3 to i8*
%9 = bitcast i32* %4 to i8*
%10 = bitcast [50 x i32]* %5 to i8*
store i32 0, i32* %1
%11 = getelementptr inbounds [50 x i32], [50 x i32]* %3, i64 0, i64 0
%12 = ptrtoint [50 x i32]* %3 to i64
%13 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 0
br label %14
14: ; preds = %78, %0
%15 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @.str, i64 0, i64 0))
%16 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
%17 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.2, i64 0, i64 0))
%18 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0))
%19 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0))
%20 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.5, i64 0, i64 0))
%21 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.6, i64 0, i64 0))
%22 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i64 0, i64 0), i32* %2)
%23 = load i32, i32* %2
switch i32 %23, label %76 [
i32 0, label %24
i32 1, label %26
i32 2, label %28
i32 3, label %31
i32 4, label %58
i32 5, label %61
]
24: ; preds = %14
%25 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i64 0, i64 0))
br label %78
26: ; preds = %14
%27 = call i32 @accept(i32* %11, i32* %1)
br label %78
28: ; preds = %14
%29 = load i32, i32* %1
%30 = call i32 @display(i32* %11, i32 %29)
br label %78
31: ; preds = %14
%32 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0))
%33 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.10, i64 0, i64 0), i32* %4)
%34 = load i32, i32* %1
%35 = load i32, i32* %4
%36 = call i32* @linsrch(i32* %11, i32 %34, i32 %35)
%37 = icmp eq i32* %36, null
br i1 %37, label %54, label %38
38: ; preds = %31, %38
%39 = phi i32* [ %52, %38 ], [ %36, %31 ]
%40 = phi i32 [ %48, %38 ], [ 0, %31 ]
%41 = ptrtoint i32* %39 to i64
%42 = sub i64 %41, %12
%43 = lshr exact i64 %42, 2
%44 = trunc i64 %43 to i32
%45 = add i32 %44, 1
%46 = zext i32 %40 to i64
%47 = getelementptr inbounds [50 x i32], [50 x i32]* %5, i64 0, i64 %46
store i32 %45, i32* %47
%48 = add i32 %40, 1
%49 = getelementptr inbounds i32, i32* %39, i64 1
%50 = load i32, i32* %1
%51 = load i32, i32* %4
%52 = call i32* @linsrch(i32* %49, i32 %50, i32 %51)
%53 = icmp eq i32* %52, null
br i1 %53, label %54, label %38
54: ; preds = %38, %31
%55 = phi i32 [ 0, %31 ], [ %48, %38 ]
%56 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.12, i64 0, i64 0))
%57 = call i32 @display(i32* %13, i32 %55)
br label %78
58: ; preds = %14
%59 = load i32, i32* %1
%60 = call i32 @isort(i32* %11, i32 %59)
br label %78
61: ; preds = %14
%62 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0))
%63 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.10, i64 0, i64 0), i32* %4)
%64 = load i32, i32* %4
%65 = load i32, i32* %1
%66 = call i32* @binsrch(i32 %64, i32* %11, i32 %65)
%67 = icmp eq i32* %66, null
br i1 %67, label %74, label %68
68: ; preds = %61
%69 = ptrtoint i32* %66 to i64
%70 = sub i64 %69, %12
%71 = ashr exact i64 %70, 2
%72 = add nsw i64 %71, 1
%73 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @.str.13, i64 0, i64 0), i64 %72)
br label %78
74: ; preds = %61
%75 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.11, i64 0, i64 0))
br label %78
76: ; preds = %14
%77 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.14, i64 0, i64 0))
br label %78
78: ; preds = %24, %26, %28, %58, %76, %54, %74, %68
%79 = load i32, i32* %2
%80 = icmp eq i32 %79, 0
br i1 %80, label %81, label %14
81: ; preds = %78
%82 = call i32 @putchar(i8 signext 10)
ret i32 0
}