#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 printf(char *, int, double, double, double);
int /*<<< orphan*/ scanf(char *, int *, int *, int *);
int main() {
  int a, b, c, s;
  double v;
  scanf("%d %d %d", &a, &b, &c);
  s = a + b + c;
  v = s / 3.0;
  return 0 *
         printf("합 : %d\n평균 : %.2lf\n%.2lf * 50 = %.0lf\n", s, v, v, v * 50);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeda(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
lea    -0x10(%rbp),%rcx
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
add    -0xc(%rbp),%eax
add    -0x10(%rbp),%eax
mov    %eax,-0x14(%rbp)
cvtsi2sdl -0x14(%rbp),%xmm0
movsd  0xea8(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
mov    -0x14(%rbp),%esi
movsd  -0x20(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm1
movsd  0xe82(%rip),%xmm2
mulsd  -0x20(%rbp),%xmm2
lea    0xe8f(%rip),%rdi
call   1030 <printf@plt>
imul   $0x0,%eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
lea    0xee5(%rip),%rdi
lea    0x14(%rsp),%rsi
lea    0x10(%rsp),%rdx
lea    0xc(%rsp),%rcx
call   1040 <scanf@plt>
mov    0x10(%rsp),%esi
add    0x14(%rsp),%esi
add    0xc(%rsp),%esi
cvtsi2sd %esi,%xmm0
divsd  0xea9(%rip),%xmm0
movsd  0xea9(%rip),%xmm2
mulsd  %xmm0,%xmm2
lea    0xeaf(%rip),%rdi
movapd %xmm0,%xmm1
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

LLVM IR (-O0):
@.str = [9 x i8] c"%d %d %d\00"
@.str.1 = [44 x i8] c"\ED\95\A9 : %d\0A\ED\8F\89\EA\B7\A0 : %.2lf\0A%.2lf * 50 = %.0lf\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca double
store i32 0, i32* %1
%7 = call i32 @scanf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32* %2, i32* %3, i32* %4)
%8 = load i32, i32* %2
%9 = load i32, i32* %3
%10 = add nsw i32 %8, %9
%11 = load i32, i32* %4
%12 = add nsw i32 %10, %11
store i32 %12, i32* %5
%13 = load i32, i32* %5
%14 = sitofp i32 %13 to double
%15 = fdiv double %14, 3.000000e+00
store double %15, double* %6
%16 = load i32, i32* %5
%17 = load double, double* %6
%18 = load double, double* %6
%19 = load double, double* %6
%20 = fmul double %19, 5.000000e+01
%21 = call i32 @printf(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.1, i64 0, i64 0), i32 %16, double %17, double %18, double %20)
%22 = mul nsw i32 0, %21
ret i32 %22
}

LLVM IR (-O2):
@.str = [9 x i8] c"%d %d %d\00"
@.str.1 = [44 x i8] c"\ED\95\A9 : %d\0A\ED\8F\89\EA\B7\A0 : %.2lf\0A%.2lf * 50 = %.0lf\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = bitcast i32* %1 to i8*
%5 = bitcast i32* %2 to i8*
%6 = bitcast i32* %3 to i8*
%7 = call i32 @scanf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i64 0, i64 0), i32* %1, i32* %2, i32* %3)
%8 = load i32, i32* %1
%9 = load i32, i32* %2
%10 = add nsw i32 %9, %8
%11 = load i32, i32* %3
%12 = add nsw i32 %10, %11
%13 = sitofp i32 %12 to double
%14 = fdiv double %13, 3.000000e+00
%15 = fmul double %14, 5.000000e+01
%16 = call i32 @printf(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.1, i64 0, i64 0), i32 %12, double %14, double %14, double %15)
ret i32 0
}