#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*/ fflush(int /*<<< orphan*/);
int /*<<< orphan*/ getchar();
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ sleep(int);
int /*<<< orphan*/ stdout;
int /*<<< orphan*/ system(char *);
int main() {
  system("clear");
  printf("\x1B[34m"
         "******************************\r\n");
  printf("\x1B[34m"
         "******************************\r\n");
  printf("\x1B[34m"
         "****** QuantumLead v1.0 ******\r\n");
  printf("\x1B[34m"
         "****** by QuantumL3aper ******\r\n");
  printf("\x1B[34m"
         "******************************\r\n");
  printf("\x1B[34m"
         "******************************\r\n\r\n");
  sleep(1);
  int i = 0;
  for (i = 0; i < 100000; i++) {
    printf("\x1b[92m"
           "\r[~] Loading %d",
           i / 1000 + 1);
    printf("%%");
  }
  printf("\n");
  fflush(stdout);
  printf("\x1B[0m"
         "\r\n\r\nSelect a website to scrape for leads:\r\n");
  printf("1) YellowPages\r\n");
  printf("2) WhitePages\r\n");
  printf("2) Facebook\r\n");
  printf("3) Canpages\r\n");
  printf("4) Canadian Business Directory\r\n");
  printf("5) Canada411\r\n");
  printf("Or, type 'A' for all (multi-threaded)\r\n\r\n");
  getchar();
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xe9a(%rip),%rdi
call   1030 <system@plt>
lea    0xe94(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe86(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe9e(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeb6(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe5c(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xec0(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    $0x1,%edi
call   1070 <sleep@plt>
movl   $0x0,-0x8(%rbp)
movl   $0x0,-0x8(%rbp)
cmpl   $0x186a0,-0x8(%rbp)
jge    121e <main+0xce>
mov    -0x8(%rbp),%eax
mov    $0x3e8,%ecx
cltd
idiv   %ecx
mov    %eax,%esi
add    $0x1,%esi
lea    0xea5(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeac(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    11d7 <main+0x87>
lea    0xf58(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x2dad(%rip),%rax
mov    (%rax),%edi
call   1060 <fflush@plt>
lea    0xe77(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe99(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe9c(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe9e(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe9e(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe9e(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeb1(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xeb2(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    $0x0,%al
call   1050 <getchar@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %rbx
push   %rax
lea    0xe86(%rip),%rdi
call   1050 <system@plt>
lea    0xedf(%rip),%rbx
mov    %rbx,%rdi
call   1040 <puts@plt>
mov    %rbx,%rdi
call   1040 <puts@plt>
lea    0xe7e(%rip),%rdi
call   1040 <puts@plt>
lea    0xe97(%rip),%rdi
call   1040 <puts@plt>
mov    %rbx,%rdi
call   1040 <puts@plt>
lea    0xecd(%rip),%rdi
call   1040 <puts@plt>
mov    $0x1,%edi
call   1090 <sleep@plt>
lea    0xe33(%rip),%rbx
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
mov    %ebp,%eax
imul   $0x10624dd3,%rax,%rsi
shr    $0x26,%rsi
add    $0x1,%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    $0x25,%edi
call   1030 <putchar@plt>
add    $0x1,%ebp
cmp    $0x186a0,%ebp
jne    11e0 <main+0x70>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0x2dc0(%rip),%rax
mov    (%rax),%edi
call   1080 <fflush@plt>
lea    0xe83(%rip),%rdi
call   1040 <puts@plt>
lea    0xea6(%rip),%rdi
call   1040 <puts@plt>
lea    0xeaa(%rip),%rdi
call   1040 <puts@plt>
lea    0xead(%rip),%rdi
call   1040 <puts@plt>
lea    0xeae(%rip),%rdi
call   1040 <puts@plt>
lea    0xeaf(%rip),%rdi
call   1040 <puts@plt>
lea    0xec3(%rip),%rdi
call   1040 <puts@plt>
lea    0xec5(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1070 <getchar@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [6 x i8] c"clear\00"
@.str.1 = [38 x i8] c"\1B[34m******************************\0D\0A\00"
@.str.2 = [38 x i8] c"\1B[34m****** QuantumLead v1.0 ******\0D\0A\00"
@.str.3 = [38 x i8] c"\1B[34m****** by QuantumL3aper ******\0D\0A\00"
@.str.4 = [40 x i8] c"\1B[34m******************************\0D\0A\0D\0A\00"
@.str.5 = [21 x i8] c"\1B[92m\0D[~] Loading %d\00"
@.str.6 = [3 x i8] c"%%\00"
@.str.7 = [2 x i8] c"\0A\00"
@stdout = global i32 0
@.str.8 = [48 x i8] c"\1B[0m\0D\0A\0D\0ASelect a website to scrape for leads:\0D\0A\00"
@.str.9 = [17 x i8] c"1) YellowPages\0D\0A\00"
@.str.10 = [16 x i8] c"2) WhitePages\0D\0A\00"
@.str.11 = [14 x i8] c"2) Facebook\0D\0A\00"
@.str.12 = [14 x i8] c"3) Canpages\0D\0A\00"
@.str.13 = [33 x i8] c"4) Canadian Business Directory\0D\0A\00"
@.str.14 = [15 x i8] c"5) Canada411\0D\0A\00"
@.str.15 = [42 x i8] c"Or, type 'A' for all (multi-threaded)\0D\0A\0D\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
%3 = call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.1, i64 0, i64 0))
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.1, i64 0, i64 0))
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.2, i64 0, i64 0))
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.3, i64 0, i64 0))
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.1, i64 0, i64 0))
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.4, i64 0, i64 0))
%10 = call i32 @sleep(i32 1)
store i32 0, i32* %2
store i32 0, i32* %2
br label %11
11: ; preds = %20, %0
%12 = load i32, i32* %2
%13 = icmp slt i32 %12, 100000
br i1 %13, label %14, label %23
14: ; preds = %11
%15 = load i32, i32* %2
%16 = sdiv i32 %15, 1000
%17 = add nsw i32 %16, 1
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.5, i64 0, i64 0), i32 %17)
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0))
br label %20
20: ; preds = %14
%21 = load i32, i32* %2
%22 = add nsw i32 %21, 1
store i32 %22, i32* %2
br label %11
23: ; preds = %11
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.7, i64 0, i64 0))
%25 = load i32, i32* @stdout
%26 = call i32 @fflush(i32 %25)
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.8, i64 0, i64 0))
%28 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.9, i64 0, i64 0))
%29 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.10, i64 0, i64 0))
%30 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.11, i64 0, i64 0))
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.12, i64 0, i64 0))
%32 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.13, i64 0, i64 0))
%33 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.14, i64 0, i64 0))
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.15, i64 0, i64 0))
%35 = call i32 (...) @getchar()
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"clear\00"
@.str.5 = [21 x i8] c"\1B[92m\0D[~] Loading %d\00"
@stdout = global i32 0
@str.17 = [37 x i8] c"\1B[34m****** QuantumLead v1.0 ******\0D\00"
@str.18 = [37 x i8] c"\1B[34m****** by QuantumL3aper ******\0D\00"
@str.19 = [37 x i8] c"\1B[34m******************************\0D\00"
@str.20 = [39 x i8] c"\1B[34m******************************\0D\0A\0D\00"
@str.21 = [47 x i8] c"\1B[0m\0D\0A\0D\0ASelect a website to scrape for leads:\0D\00"
@str.22 = [16 x i8] c"1) YellowPages\0D\00"
@str.23 = [15 x i8] c"2) WhitePages\0D\00"
@str.24 = [13 x i8] c"2) Facebook\0D\00"
@str.25 = [13 x i8] c"3) Canpages\0D\00"
@str.26 = [32 x i8] c"4) Canadian Business Directory\0D\00"
@str.27 = [14 x i8] c"5) Canada411\0D\00"
@str.28 = [41 x i8] c"Or, type 'A' for all (multi-threaded)\0D\0A\0D\00"
define i32 @main() {
%1 = tail call i32 @system(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @str.19, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @str.19, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @str.17, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @str.18, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @str.19, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.20, i64 0, i64 0))
%8 = tail call i32 @sleep(i32 1)
br label %9
9: ; preds = %0, %9
%10 = phi i32 [ 0, %0 ], [ %15, %9 ]
%11 = udiv i32 %10, 1000
%12 = add nuw nsw i32 %11, 1
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.5, i64 0, i64 0), i32 %12)
%14 = tail call i32 @putchar(i32 37)
%15 = add nuw nsw i32 %10, 1
%16 = icmp eq i32 %15, 100000
br i1 %16, label %17, label %9
17: ; preds = %9
%18 = tail call i32 @putchar(i32 10)
%19 = load i32, i32* @stdout
%20 = tail call i32 @fflush(i32 %19)
%21 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @str.21, i64 0, i64 0))
%22 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str.22, i64 0, i64 0))
%23 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str.23, i64 0, i64 0))
%24 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str.24, i64 0, i64 0))
%25 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str.25, i64 0, i64 0))
%26 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.26, i64 0, i64 0))
%27 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @str.27, i64 0, i64 0))
%28 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str.28, i64 0, i64 0))
%29 = tail call i32 (...) @getchar()
ret i32 0
}