Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>
#include<stdlib.h>
#define ll long long
#define rep(i,l,r)for(ll i=(l);i<(r);i++)

ll ans;
ll a[100010];
int main(){
	int n;
	scanf("%d",&n);
	rep(i,1,n+1)scanf("%lld",a+i);
	ll ans=0;
	rep(i,0,n+1)ans+=llabs(a[i+1]-a[i]);
	rep(i,1,n+1)printf("%lld\n",ans-llabs(a[i]-a[i-1])-llabs(a[i+1]-a[i])+llabs(a[i+1]-a[i-1]));
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	ans
	.bss
	.align 8
	.type	ans, @object
	.size	ans, 8
ans:
	.zero	8
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800080
a:
	.zero	800080
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-44(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$1, -40(%rbp)
	jmp	.L2
.L3:
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addq	$1, -40(%rbp)
.L2:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L3
	movq	$0, -32(%rbp)
	movq	$0, -24(%rbp)
	jmp	.L4
.L5:
	movq	-24(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-24(%rbp), %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rax, -32(%rbp)
	addq	$1, -24(%rbp)
.L4:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -24(%rbp)
	jl	.L5
	movq	$1, -16(%rbp)
	jmp	.L6
.L7:
	movq	-16(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	subq	$1, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	movq	-32(%rbp), %rax
	subq	%rdx, %rax
	movq	%rax, %rsi
	movq	-16(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	subq	%rax, %rsi
	movq	-16(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	subq	$1, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rsi, %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	addq	$1, -16(%rbp)
.L6:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -16(%rbp)
	jl	.L7
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L9
	call	__stack_chk_fail@PLT
.L9:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
user
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB39:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	leaq	.LC0(%rip), %rdi
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$24, %rsp
	.cfi_def_cfa_offset 64
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %ecx
	leal	1(%rcx), %edx
	cmpl	$1, %edx
	jle	.L20
	leaq	8+a(%rip), %rbp
	movl	$1, %ebx
	leaq	.LC1(%rip), %r12
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rbp, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	addq	$1, %rbx
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %ecx
	addq	$8, %rbp
	leal	1(%rcx), %eax
	cltq
	cmpq	%rbx, %rax
	jg	.L3
.L2:
	testq	%rax, %rax
	jle	.L13
	cmpq	$1, %rax
	je	.L14
	movq	%rax, %rdi
	leaq	a(%rip), %rsi
	pxor	%xmm2, %xmm2
	shrq	%rdi
	movq	%rsi, %rdx
	movdqa	%xmm2, %xmm4
	salq	$4, %rdi
	addq	%rsi, %rdi
	.p2align 4,,10
	.p2align 3
.L6:
	movdqu	8(%rdx), %xmm0
	psubq	(%rdx), %xmm0
	movdqa	%xmm4, %xmm1
	addq	$16, %rdx
	movdqa	%xmm0, %xmm3
	psrlq	$63, %xmm3
	psubq	%xmm3, %xmm1
	pxor	%xmm1, %xmm0
	psubq	%xmm1, %xmm0
	paddq	%xmm0, %xmm2
	cmpq	%rdi, %rdx
	jne	.L6
	movdqa	%xmm2, %xmm0
	movq	%rax, %rdx
	psrldq	$8, %xmm0
	andq	$-2, %rdx
	paddq	%xmm0, %xmm2
	movq	%xmm2, %r12
	testb	$1, %al
	je	.L4
.L5:
	movq	8(%rsi,%rdx,8), %rax
	subq	(%rsi,%rdx,8), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rax, %r12
.L4:
	leaq	a(%rip), %rbp
	movl	$1, %r13d
	leaq	.LC2(%rip), %rbx
	testl	%ecx, %ecx
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rbp), %rdi
	movq	16(%rbp), %rax
	addq	$1, %r13
	movq	%rdi, %rdx
	subq	0(%rbp), %rdx
	movq	%rax, %rsi
	movq	%rdx, %rcx
	negq	%rcx
	cmovs	%rdx, %rcx
	subq	%rdi, %rsi
	movq	%r12, %rdx
	movl	$1, %edi
	subq	%rcx, %rdx
	movq	%rsi, %rcx
	negq	%rcx
	cmovs	%rsi, %rcx
	subq	0(%rbp), %rax
	movq	%rbx, %rsi
	subq	%rcx, %rdx
	movq	%rax, %rcx
	negq	%rcx
	cmovns	%rcx, %rax
	addq	$8, %rbp
	addq	%rax, %rdx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	4(%rsp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, %r13
	jl	.L10
.L11:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$24, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L20:
	.cfi_restore_state
	movslq	%edx, %rax
	jmp	.L2
.L13:
	xorl	%r12d, %r12d
	jmp	.L4
.L14:
	xorl	%edx, %edx
	xorl	%r12d, %r12d
	leaq	a(%rip), %rsi
	jmp	.L5
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.size	main, .-main
	.globl	a
	.bss
	.align 32
	.type	a, @object
	.size	a, 800080
a:
	.zero	800080
	.globl	ans
	.align 8
	.type	ans, @object
	.size	ans, 8
ans:
	.zero	8
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

rule
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB39:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	leaq	.LC0(%rip), %rdi
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$24, %rsp
	.cfi_def_cfa_offset 64
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %ecx
	leal	1(%rcx), %edx
	cmpl	$1, %edx
	jle	.L20
	leaq	8+a(%rip), %rbp
	movl	$1, %ebx
	leaq	.LC1(%rip), %r12
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rbp, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	addq	$1, %rbx
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %ecx
	addq	$8, %rbp
	leal	1(%rcx), %eax
	cltq
	cmpq	%rbx, %rax
	jg	.L3
.L2:
	testq	%rax, %rax
	jle	.L13
	cmpq	$1, %rax
	je	.L14
	movq	%rax, %rdi
	leaq	a(%rip), %rsi
	pxor	%xmm2, %xmm2
	shrq	%rdi
	movq	%rsi, %rdx
	movdqa	%xmm2, %xmm4
	salq	$4, %rdi
	addq	%rsi, %rdi
	.p2align 4,,10
	.p2align 3
.L6:
	movdqu	8(%rdx), %xmm0
	psubq	(%rdx), %xmm0
	movdqa	%xmm4, %xmm1
	addq	$16, %rdx
	movdqa	%xmm0, %xmm3
	psrlq	$63, %xmm3
	psubq	%xmm3, %xmm1
	pxor	%xmm1, %xmm0
	psubq	%xmm1, %xmm0
	paddq	%xmm0, %xmm2
	cmpq	%rdi, %rdx
	jne	.L6
	movdqa	%xmm2, %xmm0
	movq	%rax, %rdx
	psrldq	$8, %xmm0
	andq	$-2, %rdx
	paddq	%xmm0, %xmm2
	movq	%xmm2, %r12
	testb	$1, %al
	je	.L4
.L5:
	movq	8(%rsi,%rdx,8), %rax
	subq	(%rsi,%rdx,8), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rax, %r12
.L4:
	leaq	a(%rip), %rbp
	movl	$1, %r13d
	leaq	.LC2(%rip), %rbx
	testl	%ecx, %ecx
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rbp), %rdi
	movq	16(%rbp), %rax
	addq	$1, %r13
	movq	%rdi, %rdx
	subq	0(%rbp), %rdx
	movq	%rax, %rsi
	movq	%rdx, %rcx
	negq	%rcx
	cmovs	%rdx, %rcx
	subq	%rdi, %rsi
	movq	%r12, %rdx
	movl	$1, %edi
	subq	%rcx, %rdx
	movq	%rsi, %rcx
	negq	%rcx
	cmovs	%rsi, %rcx
	subq	0(%rbp), %rax
	movq	%rbx, %rsi
	subq	%rcx, %rdx
	movq	%rax, %rcx
	negq	%rcx
	cmovns	%rcx, %rax
	addq	$8, %rbp
	addq	%rax, %rdx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	4(%rsp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, %r13
	jl	.L10
.L11:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$24, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L20:
	.cfi_restore_state
	movslq	%edx, %rax
	jmp	.L2
.L13:
	xorl	%r12d, %r12d
	jmp	.L4
.L14:
	xorl	%edx, %edx
	xorl	%r12d, %r12d
	leaq	a(%rip), %rsi
	jmp	.L5
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.size	main, .-main
	.globl	a
	.bss
	.align 32
	.type	a, @object
	.size	a, 800080
a:
	.zero	800080
	.globl	ans
	.align 8
	.type	ans, @object
	.size	ans, 8
ans:
	.zero	8
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

#include<stdio.h>
#include<stdlib.h>
#define ll long long
#define rep(i,l,r)for(ll i=(l);i<(r);i++)

ll ans;
ll a[100010];
int main(){
	int n;
	scanf("%d",&n);
	rep(i,1,n+1)scanf("%lld",a+i);
	ll ans=0;
	rep(i,0,n+1)ans+=llabs(a[i+1]-a[i]);
	rep(i,1,n+1)printf("%lld\n",ans-llabs(a[i]-a[i-1])-llabs(a[i+1]-a[i])+llabs(a[i+1]-a[i-1]));
	return 0;
}
6
-679 -3431 -3258 3095 -3291 -4462
 5
1 1 0 2 0
 3
2 5 -1
 6
-679 -3431 -3258 3095 -3291 -2101
 5
1 0 0 2 0
 3
2 5 -2
 6
-679 -3431 -3258 3095 -4122 -2101
 5
1 0 0 2 1
 3
3 5 -2
 6
-679 -52 -3258 3095 -4122 -2101

21976
21630
21976
9270
21976
19634
 6
6
4
2
6
 12
6
10
 19634
19288
19634
6928
17254
19634
 4
6
6
2
6
 14
8
10
 21296
20950
21296
8590
17254
21296
 4
6
6
4
6
 14
10
10
 20950
20950
15792
9498
18162
22204

Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>
#include<stdlib.h>
#define ll long long
#define rep(i,l,r)for(ll i=(l);i<(r);i++)

ll ans;
ll a[100010];
int main(){
	int n;
	scanf("%d",&n);
	rep(i,1,n+1)scanf("%lld",a+i);
	ll ans=0;
	rep(i,0,n+1)ans+=llabs(a[i+1]-a[i]);
	rep(i,1,n+1)printf("%lld\n",ans-llabs(a[i]-a[i-1])-llabs(a[i+1]-a[i])+llabs(a[i+1]-a[i-1]));
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	ans
	.bss
	.align 8
	.type	ans, @object
	.size	ans, 8
ans:
	.zero	8
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800080
a:
	.zero	800080
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-44(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$1, -40(%rbp)
	jmp	.L2
.L3:
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addq	$1, -40(%rbp)
.L2:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L3
	movq	$0, -32(%rbp)
	movq	$0, -24(%rbp)
	jmp	.L4
.L5:
	movq	-24(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-24(%rbp), %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rax, -32(%rbp)
	addq	$1, -24(%rbp)
.L4:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -24(%rbp)
	jl	.L5
	movq	$1, -16(%rbp)
	jmp	.L6
.L7:
	movq	-16(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	subq	$1, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	movq	-32(%rbp), %rax
	subq	%rdx, %rax
	movq	%rax, %rsi
	movq	-16(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	subq	%rax, %rsi
	movq	-16(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	subq	$1, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rsi, %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	addq	$1, -16(%rbp)
.L6:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -16(%rbp)
	jl	.L7
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L9
	call	__stack_chk_fail@PLT
.L9:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
train
	.file	"temp.c"
	.text
	.globl	ans
	.bss
	.align 8
	.type	ans, @object
	.size	ans, 8
ans:
	.zero	8
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800080
a:
	.zero	800080
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-44(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$1, -40(%rbp)
	jmp	.L2
.L3:
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addq	$1, -40(%rbp)
.L2:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L3
	movq	$0, -32(%rbp)
	movq	$0, -24(%rbp)
	jmp	.L4
.L5:
	movq	-24(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-24(%rbp), %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rax, -32(%rbp)
	addq	$1, -24(%rbp)
.L4:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -24(%rbp)
	jl	.L5
	movq	$1, -16(%rbp)
	jmp	.L6
.L7:
	movq	-16(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	subq	$1, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	movq	-32(%rbp), %rax
	subq	%rdx, %rax
	movq	%rax, %rsi
	movq	-16(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	subq	%rax, %rsi
	movq	-16(%rbp), %rax
	addq	$1, %rax
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	-16(%rbp), %rdx
	subq	$1, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovns	%rdx, %rax
	addq	%rsi, %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	addq	$1, -16(%rbp)
.L6:
	movl	-44(%rbp), %eax
	addl	$1, %eax
	cltq
	cmpq	%rax, -16(%rbp)
	jl	.L7
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L9
	call	__stack_chk_fail@PLT
.L9:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
