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

```c
#include<stdlib.h>
#include<stdio.h>

int main(){
  long s[200000],N,i,j,k,ans,bear,snuke;

  scanf("%ld",&N);
  for(i=0;i<N;i++){
    scanf("%ld",&s[i]);
  }

  bear = 0;
  for(j=1;j<N;j++){
    bear += s[j];
  }

  snuke = s[0];

  ans = labs(bear - snuke);

  for(k=1;k<N-1;k++){
    snuke += s[k];
    bear -= s[k];
    if(labs(snuke - bear)<ans){
      ans = labs(snuke -bear);
    }
  }

  printf("%ld\n",ans);
}
```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%ld"
.LC1:
	.string	"%ld\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
	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
	leaq	-1597440(%rsp), %r11
	.cfi_def_cfa 11, 1597480
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$2600, %rsp
	.cfi_def_cfa_offset 1600080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 1600024(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	cmpq	$0, 8(%rsp)
	jle	.L2
	leaq	16(%rsp), %r12
	xorl	%ebp, %ebp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movq	8(%rsp), %rsi
	addq	$8, %r12
	cmpq	%rbp, %rsi
	jg	.L3
	cmpq	$1, %rsi
	jle	.L2
	leaq	-1(%rsi), %rdi
	cmpq	$2, %rsi
	je	.L12
	movq	%rdi, %rdx
	leaq	24(%rsp), %rcx
	pxor	%xmm0, %xmm0
	shrq	%rdx
	movq	%rcx, %rax
	salq	$4, %rdx
	addq	%rcx, %rdx
	.p2align 4,,10
	.p2align 3
.L7:
	movdqu	(%rax), %xmm2
	addq	$16, %rax
	paddq	%xmm2, %xmm0
	cmpq	%rax, %rdx
	jne	.L7
	movdqa	%xmm0, %xmm1
	movq	%rdi, %rdx
	psrldq	$8, %xmm1
	orq	$1, %rdx
	andl	$1, %edi
	paddq	%xmm1, %xmm0
	movq	%xmm0, %rax
	je	.L19
.L6:
	addq	16(%rsp,%rdx,8), %rax
	movq	16(%rsp), %rdi
	movq	%rax, %rcx
	subq	%rdi, %rcx
	movq	%rcx, %rdx
	negq	%rdx
	cmovs	%rcx, %rdx
	cmpq	$2, %rsi
	jle	.L5
	leaq	24(%rsp), %rcx
.L10:
	leaq	(%rbx,%rsi,8), %r9
	.p2align 4,,10
	.p2align 3
.L9:
	addq	(%rcx), %rdi
	subq	(%rcx), %rax
	movq	%rdi, %r8
	subq	%rax, %r8
	movq	%r8, %rsi
	negq	%rsi
	cmovs	%r8, %rsi
	cmpq	%rsi, %rdx
	cmovg	%rsi, %rdx
	addq	$8, %rcx
	cmpq	%r9, %rcx
	jne	.L9
.L5:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	1600024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L20
	addq	$1600040, %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
.L19:
	.cfi_restore_state
	movq	16(%rsp), %rdi
	movq	%xmm0, %r8
	subq	%rdi, %r8
	movq	%r8, %rdx
	negq	%rdx
	cmovs	%r8, %rdx
	jmp	.L10
.L2:
	movq	16(%rsp), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	jmp	.L5
.L12:
	xorl	%eax, %eax
	movl	$1, %edx
	jmp	.L6
.L20:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.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.
Optimized Assembly Code:

user
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%ld"
.LC1:
	.string	"%ld\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
	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
	leaq	-1597440(%rsp), %r11
	.cfi_def_cfa 11, 1597480
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$2600, %rsp
	.cfi_def_cfa_offset 1600080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 1600024(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	cmpq	$0, 8(%rsp)
	jle	.L2
	leaq	16(%rsp), %r12
	xorl	%ebp, %ebp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movq	8(%rsp), %rsi
	addq	$8, %r12
	cmpq	%rbp, %rsi
	jg	.L3
	cmpq	$1, %rsi
	jle	.L2
	leaq	-1(%rsi), %rdi
	cmpq	$2, %rsi
	je	.L12
	movq	%rdi, %rdx
	leaq	24(%rsp), %rcx
	pxor	%xmm0, %xmm0
	shrq	%rdx
	movq	%rcx, %rax
	salq	$4, %rdx
	addq	%rcx, %rdx
	.p2align 4,,10
	.p2align 3
.L7:
	movdqu	(%rax), %xmm2
	addq	$16, %rax
	paddq	%xmm2, %xmm0
	cmpq	%rax, %rdx
	jne	.L7
	movdqa	%xmm0, %xmm1
	movq	%rdi, %rdx
	psrldq	$8, %xmm1
	orq	$1, %rdx
	andl	$1, %edi
	paddq	%xmm1, %xmm0
	movq	%xmm0, %rax
	je	.L19
.L6:
	addq	16(%rsp,%rdx,8), %rax
	movq	16(%rsp), %rdi
	movq	%rax, %rcx
	subq	%rdi, %rcx
	movq	%rcx, %rdx
	negq	%rdx
	cmovs	%rcx, %rdx
	cmpq	$2, %rsi
	jle	.L5
	leaq	24(%rsp), %rcx
.L10:
	leaq	(%rbx,%rsi,8), %r9
	.p2align 4,,10
	.p2align 3
.L9:
	addq	(%rcx), %rdi
	subq	(%rcx), %rax
	movq	%rdi, %r8
	subq	%rax, %r8
	movq	%r8, %rsi
	negq	%rsi
	cmovs	%r8, %rsi
	cmpq	%rsi, %rdx
	cmovg	%rsi, %rdx
	addq	$8, %rcx
	cmpq	%r9, %rcx
	jne	.L9
.L5:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	1600024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L20
	addq	$1600040, %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
.L19:
	.cfi_restore_state
	movq	16(%rsp), %rdi
	movq	%xmm0, %r8
	subq	%rdi, %r8
	movq	%r8, %rdx
	negq	%rdx
	cmovs	%r8, %rdx
	jmp	.L10
.L2:
	movq	16(%rsp), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	jmp	.L5
.L12:
	xorl	%eax, %eax
	movl	$1, %edx
	jmp	.L6
.L20:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.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:
```
rule
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%ld"
.LC1:
	.string	"%ld\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
	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
	leaq	-1597440(%rsp), %r11
	.cfi_def_cfa 11, 1597480
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$2600, %rsp
	.cfi_def_cfa_offset 1600080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 1600024(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	cmpq	$0, 8(%rsp)
	jle	.L2
	leaq	16(%rsp), %r12
	xorl	%ebp, %ebp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movq	8(%rsp), %rsi
	addq	$8, %r12
	cmpq	%rbp, %rsi
	jg	.L3
	cmpq	$1, %rsi
	jle	.L2
	leaq	-1(%rsi), %rdi
	cmpq	$2, %rsi
	je	.L12
	movq	%rdi, %rdx
	leaq	24(%rsp), %rcx
	pxor	%xmm0, %xmm0
	shrq	%rdx
	movq	%rcx, %rax
	salq	$4, %rdx
	addq	%rcx, %rdx
	.p2align 4,,10
	.p2align 3
.L7:
	movdqu	(%rax), %xmm2
	addq	$16, %rax
	paddq	%xmm2, %xmm0
	cmpq	%rax, %rdx
	jne	.L7
	movdqa	%xmm0, %xmm1
	movq	%rdi, %rdx
	psrldq	$8, %xmm1
	orq	$1, %rdx
	andl	$1, %edi
	paddq	%xmm1, %xmm0
	movq	%xmm0, %rax
	je	.L19
.L6:
	addq	16(%rsp,%rdx,8), %rax
	movq	16(%rsp), %rdi
	movq	%rax, %rcx
	subq	%rdi, %rcx
	movq	%rcx, %rdx
	negq	%rdx
	cmovs	%rcx, %rdx
	cmpq	$2, %rsi
	jle	.L5
	leaq	24(%rsp), %rcx
.L10:
	leaq	(%rbx,%rsi,8), %r9
	.p2align 4,,10
	.p2align 3
.L9:
	addq	(%rcx), %rdi
	subq	(%rcx), %rax
	movq	%rdi, %r8
	subq	%rax, %r8
	movq	%r8, %rsi
	negq	%rsi
	cmovs	%r8, %rsi
	cmpq	%rsi, %rdx
	cmovg	%rsi, %rdx
	addq	$8, %rcx
	cmpq	%r9, %rcx
	jne	.L9
.L5:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	1600024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L20
	addq	$1600040, %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
.L19:
	.cfi_restore_state
	movq	16(%rsp), %rdi
	movq	%xmm0, %r8
	subq	%rdi, %r8
	movq	%r8, %rdx
	negq	%rdx
	cmovs	%r8, %rdx
	jmp	.L10
.L2:
	movq	16(%rsp), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	jmp	.L5
.L12:
	xorl	%eax, %eax
	movl	$1, %edx
	jmp	.L6
.L20:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.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:
```
```c
#include<stdlib.h>
#include<stdio.h>

int main(){
  long s[200000],N,i,j,k,ans,bear,snuke;

  scanf("%ld",&N);
  for(i=0;i<N;i++){
    scanf("%ld",&s[i]);
  }

  bear = 0;
  for(j=1;j<N;j++){
    bear += s[j];
  }

  snuke = s[0];

  ans = labs(bear - snuke);

  for(k=1;k<N-1;k++){
    snuke += s[k];
    bear -= s[k];
    if(labs(snuke - bear)<ans){
      ans = labs(snuke -bear);
    }
  }

  printf("%ld\n",ans);
}
```
Given the following C code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdlib.h>
#include<stdio.h>

int main(){
  long s[200000],N,i,j,k,ans,bear,snuke;

  scanf("%ld",&N);
  for(i=0;i<N;i++){
    scanf("%ld",&s[i]);
  }

  bear = 0;
  for(j=1;j<N;j++){
    bear += s[j];
  }

  snuke = s[0];

  ans = labs(bear - snuke);

  for(k=1;k<N-1;k++){
    snuke += s[k];
    bear -= s[k];
    if(labs(snuke - bear)<ans){
      ans = labs(snuke -bear);
    }
  }

  printf("%ld\n",ans);
}
```

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.
Optimized Assembly Code:

6
1 2 3 4 5 6

1

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

```c
#include<stdlib.h>
#include<stdio.h>

int main(){
  long s[200000],N,i,j,k,ans,bear,snuke;

  scanf("%ld",&N);
  for(i=0;i<N;i++){
    scanf("%ld",&s[i]);
  }

  bear = 0;
  for(j=1;j<N;j++){
    bear += s[j];
  }

  snuke = s[0];

  ans = labs(bear - snuke);

  for(k=1;k<N-1;k++){
    snuke += s[k];
    bear -= s[k];
    if(labs(snuke - bear)<ans){
      ans = labs(snuke -bear);
    }
  }

  printf("%ld\n",ans);
}
```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%ld"
.LC1:
	.string	"%ld\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
	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
	leaq	-1597440(%rsp), %r11
	.cfi_def_cfa 11, 1597480
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$2600, %rsp
	.cfi_def_cfa_offset 1600080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 1600024(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	cmpq	$0, 8(%rsp)
	jle	.L2
	leaq	16(%rsp), %r12
	xorl	%ebp, %ebp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movq	8(%rsp), %rsi
	addq	$8, %r12
	cmpq	%rbp, %rsi
	jg	.L3
	cmpq	$1, %rsi
	jle	.L2
	leaq	-1(%rsi), %rdi
	cmpq	$2, %rsi
	je	.L12
	movq	%rdi, %rdx
	leaq	24(%rsp), %rcx
	pxor	%xmm0, %xmm0
	shrq	%rdx
	movq	%rcx, %rax
	salq	$4, %rdx
	addq	%rcx, %rdx
	.p2align 4,,10
	.p2align 3
.L7:
	movdqu	(%rax), %xmm2
	addq	$16, %rax
	paddq	%xmm2, %xmm0
	cmpq	%rax, %rdx
	jne	.L7
	movdqa	%xmm0, %xmm1
	movq	%rdi, %rdx
	psrldq	$8, %xmm1
	orq	$1, %rdx
	andl	$1, %edi
	paddq	%xmm1, %xmm0
	movq	%xmm0, %rax
	je	.L19
.L6:
	addq	16(%rsp,%rdx,8), %rax
	movq	16(%rsp), %rdi
	movq	%rax, %rcx
	subq	%rdi, %rcx
	movq	%rcx, %rdx
	negq	%rdx
	cmovs	%rcx, %rdx
	cmpq	$2, %rsi
	jle	.L5
	leaq	24(%rsp), %rcx
.L10:
	leaq	(%rbx,%rsi,8), %r9
	.p2align 4,,10
	.p2align 3
.L9:
	addq	(%rcx), %rdi
	subq	(%rcx), %rax
	movq	%rdi, %r8
	subq	%rax, %r8
	movq	%r8, %rsi
	negq	%rsi
	cmovs	%r8, %rsi
	cmpq	%rsi, %rdx
	cmovg	%rsi, %rdx
	addq	$8, %rcx
	cmpq	%r9, %rcx
	jne	.L9
.L5:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	1600024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L20
	addq	$1600040, %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
.L19:
	.cfi_restore_state
	movq	16(%rsp), %rdi
	movq	%xmm0, %r8
	subq	%rdi, %r8
	movq	%r8, %rdx
	negq	%rdx
	cmovs	%r8, %rdx
	jmp	.L10
.L2:
	movq	16(%rsp), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	jmp	.L5
.L12:
	xorl	%eax, %eax
	movl	$1, %edx
	jmp	.L6
.L20:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.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.
Optimized Assembly Code:

train
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%ld"
.LC1:
	.string	"%ld\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
	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
	leaq	-1597440(%rsp), %r11
	.cfi_def_cfa 11, 1597480
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$2600, %rsp
	.cfi_def_cfa_offset 1600080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 1600024(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	cmpq	$0, 8(%rsp)
	jle	.L2
	leaq	16(%rsp), %r12
	xorl	%ebp, %ebp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movq	8(%rsp), %rsi
	addq	$8, %r12
	cmpq	%rbp, %rsi
	jg	.L3
	cmpq	$1, %rsi
	jle	.L2
	leaq	-1(%rsi), %rdi
	cmpq	$2, %rsi
	je	.L12
	movq	%rdi, %rdx
	leaq	24(%rsp), %rcx
	pxor	%xmm0, %xmm0
	shrq	%rdx
	movq	%rcx, %rax
	salq	$4, %rdx
	addq	%rcx, %rdx
	.p2align 4,,10
	.p2align 3
.L7:
	movdqu	(%rax), %xmm2
	addq	$16, %rax
	paddq	%xmm2, %xmm0
	cmpq	%rax, %rdx
	jne	.L7
	movdqa	%xmm0, %xmm1
	movq	%rdi, %rdx
	psrldq	$8, %xmm1
	orq	$1, %rdx
	andl	$1, %edi
	paddq	%xmm1, %xmm0
	movq	%xmm0, %rax
	je	.L19
.L6:
	addq	16(%rsp,%rdx,8), %rax
	movq	16(%rsp), %rdi
	movq	%rax, %rcx
	subq	%rdi, %rcx
	movq	%rcx, %rdx
	negq	%rdx
	cmovs	%rcx, %rdx
	cmpq	$2, %rsi
	jle	.L5
	leaq	24(%rsp), %rcx
.L10:
	leaq	(%rbx,%rsi,8), %r9
	.p2align 4,,10
	.p2align 3
.L9:
	addq	(%rcx), %rdi
	subq	(%rcx), %rax
	movq	%rdi, %r8
	subq	%rax, %r8
	movq	%r8, %rsi
	negq	%rsi
	cmovs	%r8, %rsi
	cmpq	%rsi, %rdx
	cmovg	%rsi, %rdx
	addq	$8, %rcx
	cmpq	%r9, %rcx
	jne	.L9
.L5:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	1600024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L20
	addq	$1600040, %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
.L19:
	.cfi_restore_state
	movq	16(%rsp), %rdi
	movq	%xmm0, %r8
	subq	%rdi, %r8
	movq	%r8, %rdx
	negq	%rdx
	cmovs	%r8, %rdx
	jmp	.L10
.L2:
	movq	16(%rsp), %rax
	movq	%rax, %rdx
	negq	%rdx
	cmovs	%rax, %rdx
	jmp	.L5
.L12:
	xorl	%eax, %eax
	movl	$1, %edx
	jmp	.L6
.L20:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.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:
```