int main() {
  int n, i, s = 0;
  for (scanf("%d", &n), i = 5; i <= n; i += 5)
    s += i;
  printf("%d\n", s);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x10(%rbp)
lea    0xec3(%rip),%rdi
lea    -0x8(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x5,-0xc(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
jg     1172 <main+0x52>
mov    -0xc(%rbp),%eax
add    -0x10(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    -0xc(%rbp),%eax
add    $0x5,%eax
mov    %eax,-0xc(%rbp)
jmp    114f <main+0x2f>
mov    -0x10(%rbp),%esi
lea    0xe87(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
lea    0xed4(%rip),%rdi
xor    %ebx,%ebx
lea    0xc(%rsp),%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
mov    0xc(%rsp),%eax
cmp    $0x5,%eax
jl     1180 <main+0x60>
cmp    $0xa,%eax
mov    $0x9,%ecx
cmovge %eax,%ecx
xor    %eax,%eax
add    $0xfffffff7,%ecx
setne  %al
sub    %eax,%ecx
mov    $0xcccccccd,%edx
imul   %rcx,%rdx
shr    $0x22,%rdx
lea    (%rdx,%rax,1),%ecx
lea    (%rcx,%rcx,4),%esi
add    %edx,%eax
add    $0xffffffff,%eax
imul   %rax,%rcx
shr    %rcx
lea    (%rcx,%rcx,4),%eax
lea    (%rax,%rsi,2),%ebx
add    $0x5,%ebx
lea    0xe7c(%rip),%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 (i8*, ...) @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, 5
br i1 %5, label %24, label %6
6: ; preds = %0
%7 = call i32 @llvm.smax.i32(i32 %4, i32 9)
%8 = add nsw i32 %7, -9
%9 = icmp ne i32 %8, 0
%10 = zext i1 %9 to i32
%11 = sub nsw i32 %8, %10
%12 = udiv i32 %11, 5
%13 = add nuw nsw i32 %12, %10
%14 = mul i32 %13, 10
%15 = add nsw i32 %13, -1
%16 = zext i32 %15 to i33
%17 = zext i32 %13 to i33
%18 = mul i33 %16, %17
%19 = lshr i33 %18, 1
%20 = trunc i33 %19 to i32
%21 = mul i32 %20, 5
%22 = add i32 %14, %21
%23 = add i32 %22, 5
br label %24
24: ; preds = %6, %0
%25 = phi i32 [ 0, %0 ], [ %23, %6 ]
%26 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %25)
ret i32 0
}