#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*/ printf(char *);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int idade;
  scanf("%d", &idade);
  if (idade < 16) {
    printf("não eleitor\n");
  } else if (idade >= 18 && idade <= 65) {
    printf("eleitor obrigatório\n");
  } else {
    printf("eleitor facultativo\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
cmpl   $0x10,-0x8(%rbp)
jge    115a <main+0x3a>
lea    0xeb3(%rip),%rdi
call   1030 <printf@plt>
jmp    1190 <main+0x70>
cmpl   $0x12,-0x8(%rbp)
jl     117f <main+0x5f>
cmpl   $0x41,-0x8(%rbp)
jg     117f <main+0x5f>
lea    0xe9c(%rip),%rdi
call   1030 <printf@plt>
jmp    118b <main+0x6b>
lea    0xea1(%rip),%rdi
call   1030 <printf@plt>
jmp    1190 <main+0x70>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1040 <scanf@plt>
mov    0x4(%rsp),%eax
lea    -0x12(%rax),%ecx
cmp    $0x30,%ecx
lea    0xed4(%rip),%rcx
lea    0xeb9(%rip),%rdx
cmovb  %rcx,%rdx
cmp    $0x10,%eax
lea    0xed4(%rip),%rdi
cmovge %rdx,%rdi
call   1030 <puts@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [14 x i8] c"n\C3\A3o eleitor\0A\00"
@.str.2 = [22 x i8] c"eleitor obrigat\C3\B3rio\0A\00"
@.str.3 = [21 x i8] c"eleitor facultativo\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%4 = load i32, i32* %2
%5 = icmp slt i32 %4, 16
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
br label %19
8: ; preds = %0
%9 = load i32, i32* %2
%10 = icmp sge i32 %9, 18
br i1 %10, label %11, label %16
11: ; preds = %8
%12 = load i32, i32* %2
%13 = icmp sle i32 %12, 65
br i1 %13, label %14, label %16
14: ; preds = %11
%15 = call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0))
br label %18
16: ; preds = %11, %8
%17 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.3, i64 0, i64 0))
br label %18
18: ; preds = %16, %14
br label %19
19: ; preds = %18, %6
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@str = [20 x i8] c"eleitor facultativo\00"
@str.4 = [21 x i8] c"eleitor obrigat\C3\B3rio\00"
@str.5 = [13 x i8] c"n\C3\A3o eleitor\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%4 = load i32, i32* %1
%5 = icmp slt i32 %4, 16
%6 = add nsw i32 %4, -18
%7 = icmp ult i32 %6, 48
%8 = select i1 %7, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @str.4, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @str, i64 0, i64 0)
%9 = select i1 %5, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @str.5, i64 0, i64 0), i8* %8
%10 = call i32 @puts(i8* dereferenceable(1) %9)
ret i32 0
}