#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 */
struct EV_linkedNums {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ _approxSqrtAll(struct EV_linkedNums *);
long _calcMean(struct EV_linkedNums *);
struct EV_linkedNums *_getRands(long, long);
int /*<<< orphan*/ _range(struct EV_linkedNums *);
int /*<<< orphan*/ printf(char *, long);
int /*<<< orphan*/ scanf(char *, long *);
long _main() {
  long EV_seed;
  long EV_num;
  long EV_mean;
  struct EV_linkedNums *EV_nums;
  scanf("%ld", &EV_seed);
  scanf("%ld", &EV_num);
  EV_nums = _getRands(EV_seed, EV_num);
  EV_mean = _calcMean(EV_nums);
  printf("%ld\n", (long)EV_mean);
  _range(EV_nums);
  _approxSqrtAll(EV_nums);
  return 0;
}


x86 assembly (clang, -O0):
<_main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
lea    0xe91(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1080 <scanf@plt>
lea    0xe81(%rip),%rdi
lea    -0x10(%rbp),%rsi
call   1080 <scanf@plt>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <_getRands@plt>
mov    %rax,-0x20(%rbp)
mov    -0x20(%rbp),%rdi
call   1050 <_calcMean@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rsi
lea    0xe53(%rip),%rdi
call   1040 <printf@plt>
mov    -0x20(%rbp),%rdi
call   1060 <_range@plt>
mov    -0x20(%rbp),%rdi
call   1070 <_approxSqrtAll@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_main>:
push   %rbx
sub    $0x10,%rsp
lea    0xe94(%rip),%rbx
lea    0x8(%rsp),%rsi
mov    %rbx,%rdi
call   1080 <scanf@plt>
mov    %rsp,%rsi
mov    %rbx,%rdi
call   1080 <scanf@plt>
mov    0x8(%rsp),%rdi
mov    (%rsp),%rsi
call   1030 <_getRands@plt>
mov    %rax,%rbx
mov    %rax,%rdi
call   1050 <_calcMean@plt>
lea    0xe60(%rip),%rdi
mov    %rax,%rsi
call   1040 <printf@plt>
mov    %rbx,%rdi
call   1060 <_range@plt>
mov    %rbx,%rdi
call   1070 <_approxSqrtAll@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
%struct.EV_linkedNums = type { i32 }
@.str = [4 x i8] c"%ld\00"
@.str.1 = [5 x i8] c"%ld\0A\00"
define i64 @_main() {
%1 = alloca i64
%2 = alloca i64
%3 = alloca i64
%4 = alloca %struct.EV_linkedNums*
%5 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i64* %1)
%6 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i64* %2)
%7 = load i64, i64* %1
%8 = load i64, i64* %2
%9 = call %struct.EV_linkedNums* @_getRands(i64 %7, i64 %8)
store %struct.EV_linkedNums* %9, %struct.EV_linkedNums** %4
%10 = load %struct.EV_linkedNums*, %struct.EV_linkedNums** %4
%11 = call i64 @_calcMean(%struct.EV_linkedNums* %10)
store i64 %11, i64* %3
%12 = load i64, i64* %3
%13 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i64 %12)
%14 = load %struct.EV_linkedNums*, %struct.EV_linkedNums** %4
%15 = call i32 @_range(%struct.EV_linkedNums* %14)
%16 = load %struct.EV_linkedNums*, %struct.EV_linkedNums** %4
%17 = call i32 @_approxSqrtAll(%struct.EV_linkedNums* %16)
ret i64 0
}

LLVM IR (-O2):
%struct.EV_linkedNums = type { i32 }
@.str = [4 x i8] c"%ld\00"
@.str.1 = [5 x i8] c"%ld\0A\00"
define i64 @_main() {
%1 = alloca i64
%2 = alloca i64
%3 = bitcast i64* %1 to i8*
%4 = bitcast i64* %2 to i8*
%5 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i64* %1)
%6 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i64* %2)
%7 = load i64, i64* %1
%8 = load i64, i64* %2
%9 = call %struct.EV_linkedNums* @_getRands(i64 %7, i64 %8)
%10 = call i64 @_calcMean(%struct.EV_linkedNums* %9)
%11 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i64 %10)
%12 = call i32 @_range(%struct.EV_linkedNums* %9)
%13 = call i32 @_approxSqrtAll(%struct.EV_linkedNums* %9)
ret i64 0
}