#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*/ eight();
int /*<<< orphan*/ eleven();
int /*<<< orphan*/ five();
int /*<<< orphan*/ four();
int /*<<< orphan*/ fourteen();
int /*<<< orphan*/ nine();
int /*<<< orphan*/ one();
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ scanf(char *, int *);
int /*<<< orphan*/ seven();
int /*<<< orphan*/ six();
int /*<<< orphan*/ ten();
int /*<<< orphan*/ thirteen();
int /*<<< orphan*/ three();
int /*<<< orphan*/ twelve();
int /*<<< orphan*/ two();
int main() {
  int index;
  do {
    printf("\nMAIN MENU\n\n");
    printf(" 0.\texit\n");
    printf(" 1.\tprogram to generate a mathematical table\n");
    printf(" 2.\tprogram to generate the roman numeral representation\n");
    printf(" 3.\tprogram to solve a biquadratic equation\n");
    printf(" 4.\tprogram to generate the sine curve\n");
    printf(" 5.\tprogram to generate statistical markers\n");
    printf(" 6.\tprogram to generate the prime factorisation\n");
    printf(" 7.\tprogram to generate a formatted date\n");
    printf(" 8.\tprogram to gauge the accuracy of computation\n");
    printf(" 9.\tprogram to generate the binary equivalent\n");
    printf("10.\tprogram to generate the sine\n");
    printf("11.\tprogram to demostrate linear search\n");
    printf("12.\tprogram to demostrate insertion sort\n");
    printf("13.\tprogram to manipulate complex numbers\n");
    printf("14.\tprogram to generate terms of a polynomial series\n");
    printf("\nselect option (int): ");
    scanf("%d", &index);
    printf("\n");
    switch (index) {
    case 0:
      break;
    case 1:
      one();
      break;
    case 2:
      two();
      break;
    case 3:
      three();
      break;
    case 4:
      four();
      break;
    case 5:
      five();
      break;
    case 6:
      six();
      break;
    case 7:
      seven();
      break;
    case 8:
      eight();
      break;
    case 9:
      nine();
      break;
    case 10:
      ten();
      break;
    case 11:
      eleven();
      break;
    case 12:
      twelve();
      break;
    case 13:
      thirteen();
      break;
    case 14:
      fourteen();
      break;
    default:
      printf("invalid input\n");
    }
  } while (index);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xe26(%rip),%rdi
call   1080 <printf@plt>
lea    0xe27(%rip),%rdi
call   1080 <printf@plt>
lea    0xe25(%rip),%rdi
call   1080 <printf@plt>
lea    0xe47(%rip),%rdi
call   1080 <printf@plt>
lea    0xe75(%rip),%rdi
call   1080 <printf@plt>
lea    0xe96(%rip),%rdi
call   1080 <printf@plt>
lea    0xeb2(%rip),%rdi
call   1080 <printf@plt>
lea    0xed3(%rip),%rdi
call   1080 <printf@plt>
lea    0xef8(%rip),%rdi
call   1080 <printf@plt>
lea    0xf16(%rip),%rdi
call   1080 <printf@plt>
lea    0xf3c(%rip),%rdi
call   1080 <printf@plt>
lea    0xf5f(%rip),%rdi
call   1080 <printf@plt>
lea    0xf75(%rip),%rdi
call   1080 <printf@plt>
lea    0xf92(%rip),%rdi
call   1080 <printf@plt>
lea    0xfb0(%rip),%rdi
call   1080 <printf@plt>
lea    0xfcf(%rip),%rdi
call   1080 <printf@plt>
lea    0xff9(%rip),%rdi
call   1080 <printf@plt>
lea    0x1004(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   10f0 <scanf@plt>
lea    0xd55(%rip),%rdi
call   1080 <printf@plt>
mov    -0x8(%rbp),%eax
mov    %rax,-0x10(%rbp)
sub    $0xe,%rax
ja     13c9 <main+0x1c9>
mov    -0x10(%rbp),%rax
lea    0xced(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   10e0 <one@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1030 <two@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1100 <three@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   10d0 <four@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1040 <five@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   10a0 <six@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1110 <seven@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   10b0 <eight@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1060 <nine@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1090 <ten@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1070 <eleven@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1120 <twelve@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   1050 <thirteen@plt>
jmp    13d5 <main+0x1d5>
mov    $0x0,%al
call   10c0 <fourteen@plt>
jmp    13d5 <main+0x1d5>
lea    0xf19(%rip),%rdi
call   1080 <printf@plt>
jmp    13da <main+0x1da>
cmpl   $0x0,-0x8(%rbp)
jne    120f <main+0xf>
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
lea    0x1048(%rip),%r12
lea    0x106b(%rip),%r13
lea    0xdfc(%rip),%rbx
lea    0xe0c(%rip),%rbp
lea    0x4(%rsp),%r14
lea    0xdad(%rip),%r15
jmp    127b <main+0x5b>
lea    0x107d(%rip),%rdi
call   1080 <puts@plt>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
cmpl   $0x0,0x4(%rsp)
je     140f <main+0x1ef>
lea    0xdd4(%rip),%rdi
call   1080 <puts@plt>
lea    0xdd4(%rip),%rdi
call   1080 <puts@plt>
lea    0xdd1(%rip),%rdi
call   1080 <puts@plt>
lea    0xdf2(%rip),%rdi
call   1080 <puts@plt>
lea    0xe1f(%rip),%rdi
call   1080 <puts@plt>
lea    0xe3f(%rip),%rdi
call   1080 <puts@plt>
lea    0xe5a(%rip),%rdi
call   1080 <puts@plt>
lea    0xe7a(%rip),%rdi
call   1080 <puts@plt>
lea    0xe9e(%rip),%rdi
call   1080 <puts@plt>
lea    0xebb(%rip),%rdi
call   1080 <puts@plt>
lea    0xee0(%rip),%rdi
call   1080 <puts@plt>
lea    0xf02(%rip),%rdi
call   1080 <puts@plt>
lea    0xf17(%rip),%rdi
call   1080 <puts@plt>
lea    0xf33(%rip),%rdi
call   1080 <puts@plt>
mov    %r12,%rdi
call   1080 <puts@plt>
mov    %r13,%rdi
call   1080 <puts@plt>
mov    %rbx,%rdi
call   10a0 <printf@plt>
mov    %rbp,%rdi
mov    %r14,%rsi
call   1110 <scanf@plt>
mov    $0xa,%edi
call   1050 <putchar@plt>
mov    0x4(%rsp),%eax
cmp    $0xe,%rax
ja     1255 <main+0x35>
movslq (%r15,%rax,4),%rax
add    %r15,%rax
jmp    *%rax
xor    %eax,%eax
call   1100 <one@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1030 <two@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1120 <three@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   10f0 <four@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1040 <five@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   10c0 <six@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1130 <seven@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   10d0 <eight@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1070 <nine@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   10b0 <ten@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1090 <eleven@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1140 <twelve@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   1060 <thirteen@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
call   10e0 <fourteen@plt>
jmp    1270 <main+0x50>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [13 x i8] c"\0AMAIN MENU\0A\0A\00"
@.str.1 = [10 x i8] c" 0.\09exit\0A\00"
@.str.2 = [46 x i8] c" 1.\09program to generate a mathematical table\0A\00"
@.str.3 = [58 x i8] c" 2.\09program to generate the roman numeral representation\0A\00"
@.str.4 = [45 x i8] c" 3.\09program to solve a biquadratic equation\0A\00"
@.str.5 = [40 x i8] c" 4.\09program to generate the sine curve\0A\00"
@.str.6 = [45 x i8] c" 5.\09program to generate statistical markers\0A\00"
@.str.7 = [49 x i8] c" 6.\09program to generate the prime factorisation\0A\00"
@.str.8 = [42 x i8] c" 7.\09program to generate a formatted date\0A\00"
@.str.9 = [50 x i8] c" 8.\09program to gauge the accuracy of computation\0A\00"
@.str.10 = [47 x i8] c" 9.\09program to generate the binary equivalent\0A\00"
@.str.11 = [34 x i8] c"10.\09program to generate the sine\0A\00"
@.str.12 = [41 x i8] c"11.\09program to demostrate linear search\0A\00"
@.str.13 = [42 x i8] c"12.\09program to demostrate insertion sort\0A\00"
@.str.14 = [43 x i8] c"13.\09program to manipulate complex numbers\0A\00"
@.str.15 = [54 x i8] c"14.\09program to generate terms of a polynomial series\0A\00"
@.str.16 = [23 x i8] c"\0Aselect option (int): \00"
@.str.17 = [3 x i8] c"%d\00"
@.str.18 = [2 x i8] c"\0A\00"
@.str.19 = [15 x i8] c"invalid input\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
br label %3
3: ; preds = %56, %0
%4 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.2, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.3, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.4, i64 0, i64 0))
%9 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.5, i64 0, i64 0))
%10 = call i32 @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.6, i64 0, i64 0))
%11 = call i32 @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.7, i64 0, i64 0))
%12 = call i32 @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.8, i64 0, i64 0))
%13 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.9, i64 0, i64 0))
%14 = call i32 @printf(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.10, i64 0, i64 0))
%15 = call i32 @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.11, i64 0, i64 0))
%16 = call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.12, i64 0, i64 0))
%17 = call i32 @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.13, i64 0, i64 0))
%18 = call i32 @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.14, i64 0, i64 0))
%19 = call i32 @printf(i8* getelementptr inbounds ([54 x i8], [54 x i8]* @.str.15, i64 0, i64 0))
%20 = call i32 @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.16, i64 0, i64 0))
%21 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.17, i64 0, i64 0), i32* %2)
%22 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.18, i64 0, i64 0))
%23 = load i32, i32* %2
switch i32 %23, label %53 [
i32 0, label %24
i32 1, label %25
i32 2, label %27
i32 3, label %29
i32 4, label %31
i32 5, label %33
i32 6, label %35
i32 7, label %37
i32 8, label %39
i32 9, label %41
i32 10, label %43
i32 11, label %45
i32 12, label %47
i32 13, label %49
i32 14, label %51
]
24: ; preds = %3
br label %55
25: ; preds = %3
%26 = call i32 (...) @one()
br label %55
27: ; preds = %3
%28 = call i32 (...) @two()
br label %55
29: ; preds = %3
%30 = call i32 (...) @three()
br label %55
31: ; preds = %3
%32 = call i32 (...) @four()
br label %55
33: ; preds = %3
%34 = call i32 (...) @five()
br label %55
35: ; preds = %3
%36 = call i32 (...) @six()
br label %55
37: ; preds = %3
%38 = call i32 (...) @seven()
br label %55
39: ; preds = %3
%40 = call i32 (...) @eight()
br label %55
41: ; preds = %3
%42 = call i32 (...) @nine()
br label %55
43: ; preds = %3
%44 = call i32 (...) @ten()
br label %55
45: ; preds = %3
%46 = call i32 (...) @eleven()
br label %55
47: ; preds = %3
%48 = call i32 (...) @twelve()
br label %55
49: ; preds = %3
%50 = call i32 (...) @thirteen()
br label %55
51: ; preds = %3
%52 = call i32 (...) @fourteen()
br label %55
53: ; preds = %3
%54 = call i32 @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.19, i64 0, i64 0))
br label %55
55: ; preds = %53, %51, %49, %47, %45, %43, %41, %39, %37, %35, %33, %31, %29, %27, %25, %24
br label %56
56: ; preds = %55
%57 = load i32, i32* %2
%58 = icmp ne i32 %57, 0
br i1 %58, label %3, label %59
59: ; preds = %56
ret i32 0
}

LLVM IR (-O2):
@.str.16 = [23 x i8] c"\0Aselect option (int): \00"
@.str.17 = [3 x i8] c"%d\00"
@str = [12 x i8] c"\0AMAIN MENU\0A\00"
@str.20 = [9 x i8] c" 0.\09exit\00"
@str.21 = [45 x i8] c" 1.\09program to generate a mathematical table\00"
@str.22 = [57 x i8] c" 2.\09program to generate the roman numeral representation\00"
@str.23 = [44 x i8] c" 3.\09program to solve a biquadratic equation\00"
@str.24 = [39 x i8] c" 4.\09program to generate the sine curve\00"
@str.25 = [44 x i8] c" 5.\09program to generate statistical markers\00"
@str.26 = [48 x i8] c" 6.\09program to generate the prime factorisation\00"
@str.27 = [41 x i8] c" 7.\09program to generate a formatted date\00"
@str.28 = [49 x i8] c" 8.\09program to gauge the accuracy of computation\00"
@str.29 = [46 x i8] c" 9.\09program to generate the binary equivalent\00"
@str.30 = [33 x i8] c"10.\09program to generate the sine\00"
@str.31 = [40 x i8] c"11.\09program to demostrate linear search\00"
@str.32 = [41 x i8] c"12.\09program to demostrate insertion sort\00"
@str.33 = [42 x i8] c"13.\09program to manipulate complex numbers\00"
@str.34 = [53 x i8] c"14.\09program to generate terms of a polynomial series\00"
@str.35 = [14 x i8] c"invalid input\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
br label %3
3: ; preds = %54, %0
%4 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str, i64 0, i64 0))
%5 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str.20, i64 0, i64 0))
%6 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.21, i64 0, i64 0))
%7 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([57 x i8], [57 x i8]* @str.22, i64 0, i64 0))
%8 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([44 x i8], [44 x i8]* @str.23, i64 0, i64 0))
%9 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.24, i64 0, i64 0))
%10 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([44 x i8], [44 x i8]* @str.25, i64 0, i64 0))
%11 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str.26, i64 0, i64 0))
%12 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str.27, i64 0, i64 0))
%13 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str.28, i64 0, i64 0))
%14 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([46 x i8], [46 x i8]* @str.29, i64 0, i64 0))
%15 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.30, i64 0, i64 0))
%16 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @str.31, i64 0, i64 0))
%17 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str.32, i64 0, i64 0))
%18 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @str.33, i64 0, i64 0))
%19 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([53 x i8], [53 x i8]* @str.34, i64 0, i64 0))
%20 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.16, i64 0, i64 0))
%21 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.17, i64 0, i64 0), i32* %1)
%22 = call i32 @putchar(i32 10)
%23 = load i32, i32* %1
switch i32 %23, label %52 [
i32 0, label %57
i32 1, label %24
i32 2, label %26
i32 3, label %28
i32 4, label %30
i32 5, label %32
i32 6, label %34
i32 7, label %36
i32 8, label %38
i32 9, label %40
i32 10, label %42
i32 11, label %44
i32 12, label %46
i32 13, label %48
i32 14, label %50
]
24: ; preds = %3
%25 = call i32 (...) @one()
br label %54
26: ; preds = %3
%27 = call i32 (...) @two()
br label %54
28: ; preds = %3
%29 = call i32 (...) @three()
br label %54
30: ; preds = %3
%31 = call i32 (...) @four()
br label %54
32: ; preds = %3
%33 = call i32 (...) @five()
br label %54
34: ; preds = %3
%35 = call i32 (...) @six()
br label %54
36: ; preds = %3
%37 = call i32 (...) @seven()
br label %54
38: ; preds = %3
%39 = call i32 (...) @eight()
br label %54
40: ; preds = %3
%41 = call i32 (...) @nine()
br label %54
42: ; preds = %3
%43 = call i32 (...) @ten()
br label %54
44: ; preds = %3
%45 = call i32 (...) @eleven()
br label %54
46: ; preds = %3
%47 = call i32 (...) @twelve()
br label %54
48: ; preds = %3
%49 = call i32 (...) @thirteen()
br label %54
50: ; preds = %3
%51 = call i32 (...) @fourteen()
br label %54
52: ; preds = %3
%53 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @str.35, i64 0, i64 0))
br label %54
54: ; preds = %24, %26, %28, %30, %32, %34, %36, %38, %40, %42, %44, %46, %48, %50, %52
%55 = load i32, i32* %1
%56 = icmp eq i32 %55, 0
br i1 %56, label %57, label %3
57: ; preds = %3, %54
ret i32 0
}