#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*/ esVocal(char);
int /*<<< orphan*/ genImpar(int);
int /*<<< orphan*/ genPar(int);
int menu();
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ scanf(char *, ...);
int /*<<< orphan*/ system(char *);
int /*<<< orphan*/ volumenCilindro(float, float);
int main() {
  int aux, num;
  float radio, altura;
  char caracter;
  do {
    aux = menu();
    system("cls");
    switch (aux) {
    case 1:
      printf("Hola mundo cruel \n");
      break;
    case 2:
      printf("¿Cuantos impares quieres generar? \n");
      scanf("%d", &num);
      genImpar(num);
      break;
    case 3:
      printf("¿Cuantos pares quieres generar? \n");
      scanf("%d", &num);
      genPar(num);
      break;
    case 4:
      printf("Ingrese un radio: ");
      scanf("%f", &radio);
      printf("Ingrese una altura: ");
      scanf("%f", &altura);
      volumenCilindro(radio, altura);
      break;
    case 5:
      printf("Introduzca una letra \n");
      scanf("%s", &caracter);
      esVocal(caracter);
      break;
    case 0:
      printf("Hasta luego \n");
      break;
    default:
      printf("Opcion invalida \n");
    }
  } while (aux != 0);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
xor    %eax,%eax
call   1040 <menu@plt>
mov    %eax,-0x8(%rbp)
lea    0xe78(%rip),%rdi
call   1060 <system@plt>
mov    -0x8(%rbp),%eax
mov    %rax,-0x20(%rbp)
sub    $0x5,%rax
ja     12be <main+0x13e>
mov    -0x20(%rbp),%rax
lea    0xe3f(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xe4b(%rip),%rdi
call   1070 <printf@plt>
jmp    12ca <main+0x14a>
lea    0xe4d(%rip),%rdi
call   1070 <printf@plt>
lea    0xe66(%rip),%rdi
lea    -0xc(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0xc(%rbp),%edi
call   1080 <genImpar@plt>
jmp    12ca <main+0x14a>
lea    0xe4a(%rip),%rdi
call   1070 <printf@plt>
lea    0xe3b(%rip),%rdi
lea    -0xc(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0xc(%rbp),%edi
call   1050 <genPar@plt>
jmp    12ca <main+0x14a>
lea    0xe42(%rip),%rdi
call   1070 <printf@plt>
lea    0xe49(%rip),%rdi
lea    -0x10(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
lea    0xe3a(%rip),%rdi
call   1070 <printf@plt>
lea    0xe2b(%rip),%rdi
lea    -0x14(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
movss  -0x10(%rbp),%xmm0
movss  -0x14(%rbp),%xmm1
call   1030 <volumenCilindro@plt>
jmp    12ca <main+0x14a>
lea    0xe1d(%rip),%rdi
call   1070 <printf@plt>
lea    0xe28(%rip),%rdi
lea    -0x15(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
movsbl -0x15(%rbp),%edi
call   1090 <esVocal@plt>
jmp    12ca <main+0x14a>
lea    0xe0b(%rip),%rdi
call   1070 <printf@plt>
jmp    12ca <main+0x14a>
lea    0xe08(%rip),%rdi
call   1070 <printf@plt>
jmp    12cf <main+0x14f>
cmpl   $0x0,-0x8(%rbp)
jne    118f <main+0xf>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
lea    0xe73(%rip),%rbx
lea    0xe54(%rip),%r15
lea    0xe69(%rip),%r13
lea    0xc(%rsp),%rbp
lea    0xe73(%rip),%r12
jmp    11f0 <main+0x60>
lea    0xe92(%rip),%rdi
call   1040 <puts@plt>
lea    0xe76(%rip),%rdi
lea    0xb(%rsp),%rsi
xor    %eax,%eax
call   10b0 <scanf@plt>
movsbl 0xb(%rsp),%edi
call   10a0 <esVocal@plt>
nopw   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1050 <menu@plt>
mov    %eax,%r14d
mov    %rbx,%rdi
call   1070 <system@plt>
cmp    $0x5,%r14d
ja     1222 <main+0x92>
mov    %r14d,%eax
movslq (%r15,%rax,4),%rax
add    %r15,%rax
jmp    *%rax
lea    0xe9b(%rip),%rdi
call   1040 <puts@plt>
jmp    11f0 <main+0x60>
lea    0xe9f(%rip),%rdi
call   1040 <puts@plt>
jmp    11f0 <main+0x60>
lea    0xe5b(%rip),%rdi
call   1040 <puts@plt>
mov    %r13,%rdi
mov    %rbp,%rsi
xor    %eax,%eax
call   10b0 <scanf@plt>
mov    0xc(%rsp),%edi
call   1090 <genImpar@plt>
jmp    11f0 <main+0x60>
lea    0xe15(%rip),%rdi
call   1040 <puts@plt>
mov    %r13,%rdi
mov    %rbp,%rsi
xor    %eax,%eax
call   10b0 <scanf@plt>
mov    0xc(%rsp),%edi
call   1060 <genPar@plt>
jmp    11f0 <main+0x60>
lea    0xd9d(%rip),%rdi
call   1080 <printf@plt>
mov    %r12,%rdi
lea    0x14(%rsp),%rsi
xor    %eax,%eax
call   10b0 <scanf@plt>
lea    0xd98(%rip),%rdi
call   1080 <printf@plt>
mov    %r12,%rdi
lea    0x10(%rsp),%rsi
xor    %eax,%eax
call   10b0 <scanf@plt>
movss  0x14(%rsp),%xmm0
movss  0x10(%rsp),%xmm1
call   1030 <volumenCilindro@plt>
jmp    11f0 <main+0x60>
lea    0xd7f(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [4 x i8] c"cls\00"
@.str.1 = [19 x i8] c"Hola mundo cruel \0A\00"
@.str.2 = [37 x i8] c"\C2\BFCuantos impares quieres generar? \0A\00"
@.str.3 = [3 x i8] c"%d\00"
@.str.4 = [35 x i8] c"\C2\BFCuantos pares quieres generar? \0A\00"
@.str.5 = [19 x i8] c"Ingrese un radio: \00"
@.str.6 = [3 x i8] c"%f\00"
@.str.7 = [21 x i8] c"Ingrese una altura: \00"
@.str.8 = [23 x i8] c"Introduzca una letra \0A\00"
@.str.9 = [3 x i8] c"%s\00"
@.str.10 = [14 x i8] c"Hasta luego \0A\00"
@.str.11 = [18 x i8] c"Opcion invalida \0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca float
%5 = alloca float
%6 = alloca i8
store i32 0, i32* %1
br label %7
7: ; preds = %41, %0
%8 = call i32 (...) @menu()
store i32 %8, i32* %2
%9 = call i32 @system(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%10 = load i32, i32* %2
switch i32 %10, label %38 [
i32 1, label %11
i32 2, label %13
i32 3, label %18
i32 4, label %23
i32 5, label %31
i32 0, label %36
]
11: ; preds = %7
%12 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.1, i64 0, i64 0))
br label %40
13: ; preds = %7
%14 = call i32 @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0))
%15 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %3)
%16 = load i32, i32* %3
%17 = call i32 @genImpar(i32 %16)
br label %40
18: ; preds = %7
%19 = call i32 @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.4, i64 0, i64 0))
%20 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %3)
%21 = load i32, i32* %3
%22 = call i32 @genPar(i32 %21)
br label %40
23: ; preds = %7
%24 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.5, i64 0, i64 0))
%25 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), float* %4)
%26 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.7, i64 0, i64 0))
%27 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), float* %5)
%28 = load float, float* %4
%29 = load float, float* %5
%30 = call i32 @volumenCilindro(float %28, float %29)
br label %40
31: ; preds = %7
%32 = call i32 @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.8, i64 0, i64 0))
%33 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0), i8* %6)
%34 = load i8, i8* %6
%35 = call i32 @esVocal(i8 signext %34)
br label %40
36: ; preds = %7
%37 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.10, i64 0, i64 0))
br label %40
38: ; preds = %7
%39 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.11, i64 0, i64 0))
br label %40
40: ; preds = %38, %36, %31, %23, %18, %13, %11
br label %41
41: ; preds = %40
%42 = load i32, i32* %2
%43 = icmp ne i32 %42, 0
br i1 %43, label %7, label %44
44: ; preds = %41
ret i32 0
}

LLVM IR (-O2):
@.str = [4 x i8] c"cls\00"
@.str.3 = [3 x i8] c"%d\00"
@.str.5 = [19 x i8] c"Ingrese un radio: \00"
@.str.6 = [3 x i8] c"%f\00"
@.str.7 = [21 x i8] c"Ingrese una altura: \00"
@.str.9 = [3 x i8] c"%s\00"
@str = [13 x i8] c"Hasta luego \00"
@str.12 = [22 x i8] c"Introduzca una letra \00"
@str.13 = [34 x i8] c"\C2\BFCuantos pares quieres generar? \00"
@str.14 = [36 x i8] c"\C2\BFCuantos impares quieres generar? \00"
@str.15 = [18 x i8] c"Hola mundo cruel \00"
@str.16 = [17 x i8] c"Opcion invalida \00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca i8
%5 = bitcast i32* %1 to i8*
%6 = bitcast float* %2 to i8*
%7 = bitcast float* %3 to i8*
br label %8
8: ; preds = %13, %0
%9 = call i32 (...) @menu()
%10 = call i32 @system(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
switch i32 %9, label %37 [
i32 1, label %11
i32 2, label %14
i32 3, label %19
i32 4, label %24
i32 5, label %32
i32 0, label %39
]
11: ; preds = %8
%12 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @str.15, i64 0, i64 0))
br label %13
13: ; preds = %11, %14, %19, %24, %32, %37
br label %8
14: ; preds = %8
%15 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([36 x i8], [36 x i8]* @str.14, i64 0, i64 0))
%16 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %1)
%17 = load i32, i32* %1
%18 = call i32 @genImpar(i32 %17)
br label %13
19: ; preds = %8
%20 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([34 x i8], [34 x i8]* @str.13, i64 0, i64 0))
%21 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32* %1)
%22 = load i32, i32* %1
%23 = call i32 @genPar(i32 %22)
br label %13
24: ; preds = %8
%25 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @.str.5, i64 0, i64 0))
%26 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), float* %2)
%27 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.7, i64 0, i64 0))
%28 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), float* %3)
%29 = load float, float* %2
%30 = load float, float* %3
%31 = call i32 @volumenCilindro(float %29, float %30)
br label %13
32: ; preds = %8
%33 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @str.12, i64 0, i64 0))
%34 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0), i8* %4)
%35 = load i8, i8* %4
%36 = call i32 @esVocal(i8 signext %35)
br label %13
37: ; preds = %8
%38 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @str.16, i64 0, i64 0))
br label %13
39: ; preds = %8
%40 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
ret i32 0
}