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>

int main(){
  int n,i,j,h,p[20005],a[2005],b[2005],m,max=0,mm;
  scanf("%d",&h);
  scanf("%d",&n);
  for(i=0;i<n;i++){
  	scanf("%d",&a[i]);
  	scanf("%d",&b[i]);
    if(a[i]>max){
      max=a[i];
    }
  }
  mm=100000000;
  for(i=1;i<=h+max;i++){
    p[i]=100000000;
    for(j=0;j<n;j++){
      m=b[j];
      if(a[j]<i){
        m+=p[i-a[j]];
      }
      if(p[i]>m) p[i]=m;
    }
    if((i>=h)&&(mm>p[i])){
      mm=p[i];
    }
  }
  printf("%d",mm);
  return 0;
}

```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	leaq	-94208(%rsp), %r11
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	subq	$1920, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -96104(%rbp)
	leaq	-96120(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-96124(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -96116(%rbp)
	jmp	.L2
.L4:
	leaq	-96096(%rbp), %rdx
	movl	-96116(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-88064(%rbp), %rdx
	movl	-96116(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-96116(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	cmpl	%eax, -96104(%rbp)
	jge	.L3
	movl	-96116(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	movl	%eax, -96104(%rbp)
.L3:
	addl	$1, -96116(%rbp)
.L2:
	movl	-96124(%rbp), %eax
	cmpl	%eax, -96116(%rbp)
	jl	.L4
	movl	$100000000, -96100(%rbp)
	movl	$1, -96116(%rbp)
	jmp	.L5
.L11:
	movl	-96116(%rbp), %eax
	cltq
	movl	$100000000, -80032(%rbp,%rax,4)
	movl	$0, -96112(%rbp)
	jmp	.L6
.L9:
	movl	-96112(%rbp), %eax
	cltq
	movl	-88064(%rbp,%rax,4), %eax
	movl	%eax, -96108(%rbp)
	movl	-96112(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	cmpl	%eax, -96116(%rbp)
	jle	.L7
	movl	-96112(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %edx
	movl	-96116(%rbp), %eax
	subl	%edx, %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	addl	%eax, -96108(%rbp)
.L7:
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	cmpl	%eax, -96108(%rbp)
	jge	.L8
	movl	-96116(%rbp), %eax
	cltq
	movl	-96108(%rbp), %edx
	movl	%edx, -80032(%rbp,%rax,4)
.L8:
	addl	$1, -96112(%rbp)
.L6:
	movl	-96124(%rbp), %eax
	cmpl	%eax, -96112(%rbp)
	jl	.L9
	movl	-96120(%rbp), %eax
	cmpl	%eax, -96116(%rbp)
	jl	.L10
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	cmpl	%eax, -96100(%rbp)
	jle	.L10
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	movl	%eax, -96100(%rbp)
.L10:
	addl	$1, -96116(%rbp)
.L5:
	movl	-96120(%rbp), %edx
	movl	-96104(%rbp), %eax
	addl	%edx, %eax
	cmpl	%eax, -96116(%rbp)
	jle	.L11
	movl	-96100(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.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"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	-94208(%rsp), %r11
	.cfi_def_cfa 11, 94264
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1912, %rsp
	.cfi_def_cfa_offset 96176
	leaq	.LC0(%rip), %r12
	movq	%r12, %rdi
	movq	%fs:40, %rax
	movq	%rax, 96104(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	call	__isoc99_scanf@PLT
	leaq	8(%rsp), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r9d
	testl	%r9d, %r9d
	jle	.L16
	xorl	%r13d, %r13d
	xorl	%r15d, %r15d
	leaq	16(%rsp), %rbx
	leaq	8048(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	leaq	0(,%r13,4), %r14
	movq	%r12, %rdi
	xorl	%eax, %eax
	leaq	(%rbx,%r14), %rsi
	call	__isoc99_scanf@PLT
	xorl	%eax, %eax
	leaq	0(%rbp,%r14), %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	(%rbx,%r13,4), %eax
	movl	8(%rsp), %r9d
	cmpl	%eax, %r15d
	cmovl	%eax, %r15d
	addq	$1, %r13
	cmpl	%r13d, %r9d
	jg	.L3
.L2:
	movl	12(%rsp), %eax
	leal	(%rax,%r15), %r8d
	testl	%r8d, %r8d
	jle	.L17
	cmpl	$1, %eax
	jle	.L18
	leal	1(%r8), %r14d
	leaq	16084(%rsp), %r11
	movl	$1, %esi
	movslq	%r9d, %r13
	cmpl	%eax, %r14d
	cmovg	%eax, %r14d
	.p2align 4,,10
	.p2align 3
.L9:
	movl	$100000000, (%r11)
	testl	%r9d, %r9d
	jle	.L6
	xorl	%eax, %eax
	movl	$100000000, %edx
	leaq	16(%rsp), %rbx
	leaq	8048(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L8:
	movl	(%rbx,%rax,4), %edi
	movl	0(%rbp,%rax,4), %ecx
	cmpl	%esi, %edi
	jge	.L7
	movl	%esi, %r10d
	subl	%edi, %r10d
	movslq	%r10d, %rdi
	addl	16080(%rsp,%rdi,4), %ecx
.L7:
	cmpl	%ecx, %edx
	cmovg	%ecx, %edx
	addq	$1, %rax
	movl	%edx, (%r11)
	cmpq	%r13, %rax
	jne	.L8
.L6:
	addl	$1, %esi
	addq	$4, %r11
	cmpl	%r14d, %esi
	jl	.L9
	cmpl	%r8d, %esi
	jg	.L17
.L5:
	movslq	%esi, %rax
	movl	$100000000, %r14d
	movslq	%r9d, %r13
	leaq	16080(%rsp,%rax,4), %r11
	.p2align 4,,10
	.p2align 3
.L13:
	movl	$100000000, (%r11)
	testl	%r9d, %r9d
	jle	.L19
	xorl	%eax, %eax
	movl	$100000000, %edx
	leaq	16(%rsp), %rbx
	leaq	8048(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L12:
	movl	(%rbx,%rax,4), %edi
	movl	0(%rbp,%rax,4), %ecx
	cmpl	%esi, %edi
	jge	.L11
	movl	%esi, %r10d
	subl	%edi, %r10d
	movslq	%r10d, %rdi
	addl	16080(%rsp,%rdi,4), %ecx
.L11:
	cmpl	%ecx, %edx
	cmovg	%ecx, %edx
	addq	$1, %rax
	movl	%edx, (%r11)
	cmpq	%r13, %rax
	jne	.L12
.L10:
	cmpl	%edx, %r14d
	cmovg	%edx, %r14d
	addl	$1, %esi
	addq	$4, %r11
	cmpl	%esi, %r8d
	jge	.L13
.L4:
	xorl	%eax, %eax
	movl	%r14d, %edx
	movq	%r12, %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	96104(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L27
	addq	$96120, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L19:
	.cfi_restore_state
	movl	$100000000, %edx
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L18:
	movl	$1, %esi
	jmp	.L5
.L17:
	movl	$100000000, %r14d
	jmp	.L4
.L16:
	xorl	%r15d, %r15d
	jmp	.L2
.L27:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.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
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	-94208(%rsp), %r11
	.cfi_def_cfa 11, 94264
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1912, %rsp
	.cfi_def_cfa_offset 96176
	leaq	.LC0(%rip), %r12
	movq	%r12, %rdi
	movq	%fs:40, %rax
	movq	%rax, 96104(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	call	__isoc99_scanf@PLT
	leaq	8(%rsp), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r9d
	testl	%r9d, %r9d
	jle	.L16
	xorl	%r13d, %r13d
	xorl	%r15d, %r15d
	leaq	16(%rsp), %rbx
	leaq	8048(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	leaq	0(,%r13,4), %r14
	movq	%r12, %rdi
	xorl	%eax, %eax
	leaq	(%rbx,%r14), %rsi
	call	__isoc99_scanf@PLT
	xorl	%eax, %eax
	leaq	0(%rbp,%r14), %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	(%rbx,%r13,4), %eax
	movl	8(%rsp), %r9d
	cmpl	%eax, %r15d
	cmovl	%eax, %r15d
	addq	$1, %r13
	cmpl	%r13d, %r9d
	jg	.L3
.L2:
	movl	12(%rsp), %eax
	leal	(%rax,%r15), %r8d
	testl	%r8d, %r8d
	jle	.L17
	cmpl	$1, %eax
	jle	.L18
	leal	1(%r8), %r14d
	leaq	16084(%rsp), %r11
	movl	$1, %esi
	movslq	%r9d, %r13
	cmpl	%eax, %r14d
	cmovg	%eax, %r14d
	.p2align 4,,10
	.p2align 3
.L9:
	movl	$100000000, (%r11)
	testl	%r9d, %r9d
	jle	.L6
	xorl	%eax, %eax
	movl	$100000000, %edx
	leaq	16(%rsp), %rbx
	leaq	8048(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L8:
	movl	(%rbx,%rax,4), %edi
	movl	0(%rbp,%rax,4), %ecx
	cmpl	%esi, %edi
	jge	.L7
	movl	%esi, %r10d
	subl	%edi, %r10d
	movslq	%r10d, %rdi
	addl	16080(%rsp,%rdi,4), %ecx
.L7:
	cmpl	%ecx, %edx
	cmovg	%ecx, %edx
	addq	$1, %rax
	movl	%edx, (%r11)
	cmpq	%r13, %rax
	jne	.L8
.L6:
	addl	$1, %esi
	addq	$4, %r11
	cmpl	%r14d, %esi
	jl	.L9
	cmpl	%r8d, %esi
	jg	.L17
.L5:
	movslq	%esi, %rax
	movl	$100000000, %r14d
	movslq	%r9d, %r13
	leaq	16080(%rsp,%rax,4), %r11
	.p2align 4,,10
	.p2align 3
.L13:
	movl	$100000000, (%r11)
	testl	%r9d, %r9d
	jle	.L19
	xorl	%eax, %eax
	movl	$100000000, %edx
	leaq	16(%rsp), %rbx
	leaq	8048(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L12:
	movl	(%rbx,%rax,4), %edi
	movl	0(%rbp,%rax,4), %ecx
	cmpl	%esi, %edi
	jge	.L11
	movl	%esi, %r10d
	subl	%edi, %r10d
	movslq	%r10d, %rdi
	addl	16080(%rsp,%rdi,4), %ecx
.L11:
	cmpl	%ecx, %edx
	cmovg	%ecx, %edx
	addq	$1, %rax
	movl	%edx, (%r11)
	cmpq	%r13, %rax
	jne	.L12
.L10:
	cmpl	%edx, %r14d
	cmovg	%edx, %r14d
	addl	$1, %esi
	addq	$4, %r11
	cmpl	%esi, %r8d
	jge	.L13
.L4:
	xorl	%eax, %eax
	movl	%r14d, %edx
	movq	%r12, %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	96104(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L27
	addq	$96120, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L19:
	.cfi_restore_state
	movl	$100000000, %edx
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L18:
	movl	$1, %esi
	jmp	.L5
.L17:
	movl	$100000000, %r14d
	jmp	.L4
.L16:
	xorl	%r15d, %r15d
	jmp	.L2
.L27:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.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:

#include <stdio.h>

int main(){
  int n,i,j,h,p[20005],a[2005],b[2005],m,max=0,mm;
  scanf("%d",&h);
  scanf("%d",&n);
  for(i=0;i<n;i++){
  	scanf("%d",&a[i]);
  	scanf("%d",&b[i]);
    if(a[i]>max){
      max=a[i];
    }
  }
  mm=100000000;
  for(i=1;i<=h+max;i++){
    p[i]=100000000;
    for(j=0;j<n;j++){
      m=b[j];
      if(a[j]<i){
        m+=p[i-a[j]];
      }
      if(p[i]>m) p[i]=m;
    }
    if((i>=h)&&(mm>p[i])){
      mm=p[i];
    }
  }
  printf("%d",mm);
  return 0;
}


9999 10
540 7550
691 13640
700 9790
510 7150
415 5818
551 7712
587 8227
619 8671
588 8228
176 2461
 100 6
1 1
2 3
3 9
4 27
5 81
5 243
 110 6
1 1
2 3
3 9
4 27
5 81
5 243
 9999 10
540 7550
691 20670
700 9790
863 7150
415 5818
551 7712
587 8227
619 8671
588 8228
176 2461
 9999 10
540 7550
691 20670
700 9790
863 7150
415 1114
551 7712
587 8227
941 8671
588 10398
176 2461
 9999 5
540 4853
1222 7523
1778 16913
231 7150
415 769
118 7712
1118 8227
908 8671
94 4378
37 2120
 9999 5
289 4853
1222 12181
1778 16913
231 7150
415 1085
118 7712
1118 8227
1028 8975
94 5576
37 2120
 18187 7
197 2752
1222 10579
1778 16891
231 7150
415 1085
118 7083
813 10801
1028 8975
94 737
72 2120

139815 100 110 85800 27850 19225 27125 47740
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>

int main(){
  int n,i,j,h,p[20005],a[2005],b[2005],m,max=0,mm;
  scanf("%d",&h);
  scanf("%d",&n);
  for(i=0;i<n;i++){
  	scanf("%d",&a[i]);
  	scanf("%d",&b[i]);
    if(a[i]>max){
      max=a[i];
    }
  }
  mm=100000000;
  for(i=1;i<=h+max;i++){
    p[i]=100000000;
    for(j=0;j<n;j++){
      m=b[j];
      if(a[j]<i){
        m+=p[i-a[j]];
      }
      if(p[i]>m) p[i]=m;
    }
    if((i>=h)&&(mm>p[i])){
      mm=p[i];
    }
  }
  printf("%d",mm);
  return 0;
}

```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	leaq	-94208(%rsp), %r11
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	subq	$1920, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -96104(%rbp)
	leaq	-96120(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-96124(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -96116(%rbp)
	jmp	.L2
.L4:
	leaq	-96096(%rbp), %rdx
	movl	-96116(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-88064(%rbp), %rdx
	movl	-96116(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-96116(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	cmpl	%eax, -96104(%rbp)
	jge	.L3
	movl	-96116(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	movl	%eax, -96104(%rbp)
.L3:
	addl	$1, -96116(%rbp)
.L2:
	movl	-96124(%rbp), %eax
	cmpl	%eax, -96116(%rbp)
	jl	.L4
	movl	$100000000, -96100(%rbp)
	movl	$1, -96116(%rbp)
	jmp	.L5
.L11:
	movl	-96116(%rbp), %eax
	cltq
	movl	$100000000, -80032(%rbp,%rax,4)
	movl	$0, -96112(%rbp)
	jmp	.L6
.L9:
	movl	-96112(%rbp), %eax
	cltq
	movl	-88064(%rbp,%rax,4), %eax
	movl	%eax, -96108(%rbp)
	movl	-96112(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	cmpl	%eax, -96116(%rbp)
	jle	.L7
	movl	-96112(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %edx
	movl	-96116(%rbp), %eax
	subl	%edx, %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	addl	%eax, -96108(%rbp)
.L7:
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	cmpl	%eax, -96108(%rbp)
	jge	.L8
	movl	-96116(%rbp), %eax
	cltq
	movl	-96108(%rbp), %edx
	movl	%edx, -80032(%rbp,%rax,4)
.L8:
	addl	$1, -96112(%rbp)
.L6:
	movl	-96124(%rbp), %eax
	cmpl	%eax, -96112(%rbp)
	jl	.L9
	movl	-96120(%rbp), %eax
	cmpl	%eax, -96116(%rbp)
	jl	.L10
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	cmpl	%eax, -96100(%rbp)
	jle	.L10
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	movl	%eax, -96100(%rbp)
.L10:
	addl	$1, -96116(%rbp)
.L5:
	movl	-96120(%rbp), %edx
	movl	-96104(%rbp), %eax
	addl	%edx, %eax
	cmpl	%eax, -96116(%rbp)
	jle	.L11
	movl	-96100(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.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
	.section	.rodata
.LC0:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	leaq	-94208(%rsp), %r11
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	subq	$1920, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -96104(%rbp)
	leaq	-96120(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-96124(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -96116(%rbp)
	jmp	.L2
.L4:
	leaq	-96096(%rbp), %rdx
	movl	-96116(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-88064(%rbp), %rdx
	movl	-96116(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-96116(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	cmpl	%eax, -96104(%rbp)
	jge	.L3
	movl	-96116(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	movl	%eax, -96104(%rbp)
.L3:
	addl	$1, -96116(%rbp)
.L2:
	movl	-96124(%rbp), %eax
	cmpl	%eax, -96116(%rbp)
	jl	.L4
	movl	$100000000, -96100(%rbp)
	movl	$1, -96116(%rbp)
	jmp	.L5
.L11:
	movl	-96116(%rbp), %eax
	cltq
	movl	$100000000, -80032(%rbp,%rax,4)
	movl	$0, -96112(%rbp)
	jmp	.L6
.L9:
	movl	-96112(%rbp), %eax
	cltq
	movl	-88064(%rbp,%rax,4), %eax
	movl	%eax, -96108(%rbp)
	movl	-96112(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %eax
	cmpl	%eax, -96116(%rbp)
	jle	.L7
	movl	-96112(%rbp), %eax
	cltq
	movl	-96096(%rbp,%rax,4), %edx
	movl	-96116(%rbp), %eax
	subl	%edx, %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	addl	%eax, -96108(%rbp)
.L7:
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	cmpl	%eax, -96108(%rbp)
	jge	.L8
	movl	-96116(%rbp), %eax
	cltq
	movl	-96108(%rbp), %edx
	movl	%edx, -80032(%rbp,%rax,4)
.L8:
	addl	$1, -96112(%rbp)
.L6:
	movl	-96124(%rbp), %eax
	cmpl	%eax, -96112(%rbp)
	jl	.L9
	movl	-96120(%rbp), %eax
	cmpl	%eax, -96116(%rbp)
	jl	.L10
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	cmpl	%eax, -96100(%rbp)
	jle	.L10
	movl	-96116(%rbp), %eax
	cltq
	movl	-80032(%rbp,%rax,4), %eax
	movl	%eax, -96100(%rbp)
.L10:
	addl	$1, -96116(%rbp)
.L5:
	movl	-96120(%rbp), %edx
	movl	-96104(%rbp), %eax
	addl	%edx, %eax
	cmpl	%eax, -96116(%rbp)
	jle	.L11
	movl	-96100(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.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:
