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>
long long MAX(long long a,long long b){return a<b?b:a;}
long long MIN(long long a,long long b){return a<b?a:b;}
long long d[310][310][310],c[310]={};
int main(){
  int n,m,i,j,k;
  scanf("%d %d",&n,&m);
  for(i=0;i<n;i++)scanf("%lld",&c[i+1]);
  n++;
  for(i=0;i<=n;i++){
    for(j=0;j<=n;j++){
      for(k=0;k<=m;k++)d[i][j][k]=1e18;
    }
  }
  d[0][0][0]=0;
  for(i=1;i<=n;i++){
    for(j=0;j<=i;j++){
      for(k=0;k<=m;k++){
	d[i][i][k  ]=MIN(d[i][i][k  ],d[i-1][j][k]+MAX(c[i]-c[j],0));
	d[i][j][k+1]=MIN(d[i][j][k+1],d[i-1][j][k]);
      }
    }
  }
  /*for(i=0;i<=n;i++){
    for(j=0;j<=n;j++){
      for(k=0;k<=m;k++)printf("%20lld ",d[i][j][k]);
      printf("\n");
    }
    printf("\n");
    }
    printf("\n");//*/
  printf("%lld\n",d[n][n][m]);
  return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	MAX
	.type	MAX, @function
MAX:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-8(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	MAX, .-MAX
	.globl	MIN
	.type	MIN, @function
MIN:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-16(%rbp), %rdx
	movq	-8(%rbp), %rax
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	MIN, .-MIN
	.globl	d
	.bss
	.align 32
	.type	d, @object
	.size	d, 238328000
d:
	.zero	238328000
	.globl	c
	.align 32
	.type	c, @object
	.size	c, 2480
c:
	.zero	2480
	.section	.rodata
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset 3, -24
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	leaq	-40(%rbp), %rdx
	leaq	-44(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -36(%rbp)
	jmp	.L6
.L7:
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	c(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -36(%rbp)
.L6:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jl	.L7
	movl	-44(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -44(%rbp)
	movl	$0, -36(%rbp)
	jmp	.L8
.L13:
	movl	$0, -32(%rbp)
	jmp	.L9
.L12:
	movl	$0, -28(%rbp)
	jmp	.L10
.L11:
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movl	-36(%rbp), %eax
	movslq	%eax, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movabsq	$1000000000000000000, %rbx
	movq	%rbx, (%rdx,%rax)
	addl	$1, -28(%rbp)
.L10:
	movl	-40(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L11
	addl	$1, -32(%rbp)
.L9:
	movl	-44(%rbp), %eax
	cmpl	%eax, -32(%rbp)
	jle	.L12
	addl	$1, -36(%rbp)
.L8:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L13
	movq	$0, d(%rip)
	movl	$1, -36(%rbp)
	jmp	.L14
.L19:
	movl	$0, -32(%rbp)
	jmp	.L15
.L18:
	movl	$0, -28(%rbp)
	jmp	.L16
.L17:
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movslq	%edx, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rbx
	movl	-36(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	c(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-32(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	c(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movl	$0, %esi
	movq	%rax, %rdi
	call	MAX
	leaq	(%rbx,%rax), %rdx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movl	-36(%rbp), %eax
	cltq
	imulq	$96410, %rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rcx
	leaq	d(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	MIN
	movl	-28(%rbp), %edx
	movslq	%edx, %rcx
	movl	-36(%rbp), %edx
	movslq	%edx, %rdx
	imulq	$96410, %rdx, %rdx
	addq	%rcx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	d(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movslq	%edx, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-28(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rsi
	movl	-36(%rbp), %eax
	movslq	%eax, %rcx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rcx, %rcx
	imulq	$310, %rax, %rax
	addq	%rcx, %rax
	addq	%rsi, %rax
	leaq	0(,%rax,8), %rcx
	leaq	d(%rip), %rax
	movq	(%rcx,%rax), %rax
	movl	-28(%rbp), %ecx
	leal	1(%rcx), %ebx
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	MIN
	movslq	%ebx, %rsi
	movl	-36(%rbp), %edx
	movslq	%edx, %rcx
	movl	-32(%rbp), %edx
	movslq	%edx, %rdx
	imulq	$96100, %rcx, %rcx
	imulq	$310, %rdx, %rdx
	addq	%rcx, %rdx
	addq	%rsi, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	d(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addl	$1, -28(%rbp)
.L16:
	movl	-40(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L17
	addl	$1, -32(%rbp)
.L15:
	movl	-32(%rbp), %eax
	cmpl	-36(%rbp), %eax
	jle	.L18
	addl	$1, -36(%rbp)
.L14:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L19
	movl	-44(%rbp), %edx
	movl	-44(%rbp), %eax
	movl	-40(%rbp), %ecx
	movslq	%ecx, %rcx
	movslq	%edx, %rdx
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-24(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L21
	call	__stack_chk_fail@PLT
.L21:
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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
	.p2align 4
	.globl	MAX
	.type	MAX, @function
MAX:
.LFB23:
	.cfi_startproc
	endbr64
	cmpq	%rsi, %rdi
	movq	%rsi, %rax
	cmovge	%rdi, %rax
	ret
	.cfi_endproc
.LFE23:
	.size	MAX, .-MAX
	.p2align 4
	.globl	MIN
	.type	MIN, @function
MIN:
.LFB24:
	.cfi_startproc
	endbr64
	cmpq	%rdi, %rsi
	movq	%rdi, %rax
	cmovle	%rsi, %rax
	ret
	.cfi_endproc
.LFE24:
	.size	MIN, .-MIN
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%lld"
.LC3:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB25:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC0(%rip), %rdi
	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
	subq	$56, %rsp
	.cfi_def_cfa_offset 112
	movq	%fs:40, %rax
	movq	%rax, 40(%rsp)
	xorl	%eax, %eax
	leaq	36(%rsp), %rdx
	leaq	32(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	32(%rsp), %ebp
	testl	%ebp, %ebp
	jle	.L5
	leaq	8+c(%rip), %r12
	xorl	%ebx, %ebx
	leaq	.LC1(%rip), %r13
	.p2align 4,,10
	.p2align 3
.L6:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addl	$1, %ebx
	call	__isoc99_scanf@PLT
	movl	32(%rsp), %ebp
	addq	$8, %r12
	cmpl	%ebp, %ebx
	jl	.L6
.L5:
	leal	1(%rbp), %eax
	movl	36(%rsp), %r11d
	movl	%eax, 20(%rsp)
	movl	%eax, 32(%rsp)
	testl	%eax, %eax
	js	.L7
	leaq	d(%rip), %rbx
	testl	%r11d, %r11d
	js	.L8
	leal	1(%r11), %r13d
	leal	2(%rbp), %r10d
	xorl	%r15d, %r15d
	xorl	%r14d, %r14d
	movl	%r13d, %eax
	movl	%r13d, %r9d
	movdqa	.LC2(%rip), %xmm0
	movabsq	$1000000000000000000, %rdi
	shrl	%eax
	andl	$-2, %r9d
	leal	-1(%rax), %r12d
	addq	$1, %r12
	salq	$4, %r12
	.p2align 4,,10
	.p2align 3
.L9:
	movslq	%r14d, %rcx
	leaq	(%rbx,%r15), %rsi
	xorl	%edx, %edx
	imulq	$96100, %rcx, %rcx
	.p2align 4,,10
	.p2align 3
.L17:
	leaq	(%r12,%rsi), %r8
	movq	%rsi, %rax
	testl	%r11d, %r11d
	je	.L39
	.p2align 4,,10
	.p2align 3
.L10:
	movaps	%xmm0, (%rax)
	addq	$16, %rax
	cmpq	%r8, %rax
	jne	.L10
	movslq	%r9d, %r8
	cmpl	%r13d, %r9d
	je	.L11
.L13:
	movslq	%edx, %rax
	imulq	$310, %rax, %rax
	addq	%rcx, %rax
	addq	%r8, %rax
	movq	%rdi, (%rbx,%rax,8)
.L11:
	addl	$1, %edx
	addq	$2480, %rsi
	cmpl	%r10d, %edx
	jne	.L17
	addl	$1, %r14d
	addq	$768800, %r15
	cmpl	%r10d, %r14d
	jne	.L9
.L8:
	movq	$0, d(%rip)
	movl	20(%rsp), %eax
	testl	%eax, %eax
	jle	.L38
	testl	%r11d, %r11d
	js	.L38
	movslq	%r11d, %rax
	leaq	771280+d(%rip), %r14
	movq	%rbx, 24(%rsp)
	xorl	%r8d, %r8d
	movq	%rax, %rsi
	movq	%rax, 8(%rsp)
	leaq	16+c(%rip), %r13
	leaq	-771272(%r14), %rax
	leaq	771280(%rax,%rsi,8), %r11
	leaq	8(%r13), %rax
	movq	$-768800, %r10
	leaq	(%rax,%rbp,8), %rax
	leaq	768800(%rbx), %r15
	movq	%rax, (%rsp)
	.p2align 4,,10
	.p2align 3
.L19:
	movq	-8(%r13), %r12
	leaq	(%r15,%r8), %rbp
	leaq	c(%rip), %rbx
	.p2align 4,,10
	.p2align 3
.L23:
	movl	$0, %eax
	movq	%r12, %rsi
	subq	(%rbx), %rsi
	movq	%rbp, %rdx
	cmovs	%rax, %rsi
	movq	%r14, %rax
	.p2align 4,,10
	.p2align 3
.L20:
	leaq	(%rdx,%r10), %rdi
	movq	(%rax), %r9
	movq	(%rdi,%r8), %rcx
	addq	%rsi, %rcx
	cmpq	%r9, %rcx
	cmovg	%r9, %rcx
	movq	%rcx, (%rax)
	movq	8(%rdx), %rcx
	movq	(%rdi,%r8), %rdi
	cmpq	%rdi, %rcx
	cmovg	%rdi, %rcx
	addq	$8, %rax
	addq	$8, %rdx
	movq	%rcx, (%rdx)
	cmpq	%r11, %rax
	jne	.L20
	addq	$8, %rbx
	addq	$2480, %rbp
	cmpq	%r13, %rbx
	jne	.L23
	addq	$8, %r13
	addq	$771280, %r14
	subq	$768800, %r10
	addq	$768800, %r8
	addq	$771280, %r11
	cmpq	(%rsp), %r13
	jne	.L19
	movq	24(%rsp), %rbx
.L22:
	movslq	20(%rsp), %rax
	leaq	.LC3(%rip), %rsi
	movl	$1, %edi
	imulq	$96410, %rax, %rax
	addq	8(%rsp), %rax
	movq	(%rbx,%rax,8), %rdx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L40
	addq	$56, %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
.L39:
	.cfi_restore_state
	xorl	%r8d, %r8d
	jmp	.L13
.L7:
	movq	$0, d(%rip)
	leaq	d(%rip), %rbx
.L38:
	movslq	%r11d, %rax
	movq	%rax, 8(%rsp)
	jmp	.L22
.L40:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	main, .-main
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2480
c:
	.zero	2480
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 238328000
d:
	.zero	238328000
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC2:
	.quad	1000000000000000000
	.quad	1000000000000000000
	.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
	.p2align 4
	.globl	MAX
	.type	MAX, @function
MAX:
.LFB23:
	.cfi_startproc
	endbr64
	cmpq	%rsi, %rdi
	movq	%rsi, %rax
	cmovge	%rdi, %rax
	ret
	.cfi_endproc
.LFE23:
	.size	MAX, .-MAX
	.p2align 4
	.globl	MIN
	.type	MIN, @function
MIN:
.LFB24:
	.cfi_startproc
	endbr64
	cmpq	%rdi, %rsi
	movq	%rdi, %rax
	cmovle	%rsi, %rax
	ret
	.cfi_endproc
.LFE24:
	.size	MIN, .-MIN
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%lld"
.LC3:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB25:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC0(%rip), %rdi
	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
	subq	$56, %rsp
	.cfi_def_cfa_offset 112
	movq	%fs:40, %rax
	movq	%rax, 40(%rsp)
	xorl	%eax, %eax
	leaq	36(%rsp), %rdx
	leaq	32(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	32(%rsp), %ebp
	testl	%ebp, %ebp
	jle	.L5
	leaq	8+c(%rip), %r12
	xorl	%ebx, %ebx
	leaq	.LC1(%rip), %r13
	.p2align 4,,10
	.p2align 3
.L6:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addl	$1, %ebx
	call	__isoc99_scanf@PLT
	movl	32(%rsp), %ebp
	addq	$8, %r12
	cmpl	%ebp, %ebx
	jl	.L6
.L5:
	leal	1(%rbp), %eax
	movl	36(%rsp), %r11d
	movl	%eax, 20(%rsp)
	movl	%eax, 32(%rsp)
	testl	%eax, %eax
	js	.L7
	leaq	d(%rip), %rbx
	testl	%r11d, %r11d
	js	.L8
	leal	1(%r11), %r13d
	leal	2(%rbp), %r10d
	xorl	%r15d, %r15d
	xorl	%r14d, %r14d
	movl	%r13d, %eax
	movl	%r13d, %r9d
	movdqa	.LC2(%rip), %xmm0
	movabsq	$1000000000000000000, %rdi
	shrl	%eax
	andl	$-2, %r9d
	leal	-1(%rax), %r12d
	addq	$1, %r12
	salq	$4, %r12
	.p2align 4,,10
	.p2align 3
.L9:
	movslq	%r14d, %rcx
	leaq	(%rbx,%r15), %rsi
	xorl	%edx, %edx
	imulq	$96100, %rcx, %rcx
	.p2align 4,,10
	.p2align 3
.L17:
	leaq	(%r12,%rsi), %r8
	movq	%rsi, %rax
	testl	%r11d, %r11d
	je	.L39
	.p2align 4,,10
	.p2align 3
.L10:
	movaps	%xmm0, (%rax)
	addq	$16, %rax
	cmpq	%r8, %rax
	jne	.L10
	movslq	%r9d, %r8
	cmpl	%r13d, %r9d
	je	.L11
.L13:
	movslq	%edx, %rax
	imulq	$310, %rax, %rax
	addq	%rcx, %rax
	addq	%r8, %rax
	movq	%rdi, (%rbx,%rax,8)
.L11:
	addl	$1, %edx
	addq	$2480, %rsi
	cmpl	%r10d, %edx
	jne	.L17
	addl	$1, %r14d
	addq	$768800, %r15
	cmpl	%r10d, %r14d
	jne	.L9
.L8:
	movq	$0, d(%rip)
	movl	20(%rsp), %eax
	testl	%eax, %eax
	jle	.L38
	testl	%r11d, %r11d
	js	.L38
	movslq	%r11d, %rax
	leaq	771280+d(%rip), %r14
	movq	%rbx, 24(%rsp)
	xorl	%r8d, %r8d
	movq	%rax, %rsi
	movq	%rax, 8(%rsp)
	leaq	16+c(%rip), %r13
	leaq	-771272(%r14), %rax
	leaq	771280(%rax,%rsi,8), %r11
	leaq	8(%r13), %rax
	movq	$-768800, %r10
	leaq	(%rax,%rbp,8), %rax
	leaq	768800(%rbx), %r15
	movq	%rax, (%rsp)
	.p2align 4,,10
	.p2align 3
.L19:
	movq	-8(%r13), %r12
	leaq	(%r15,%r8), %rbp
	leaq	c(%rip), %rbx
	.p2align 4,,10
	.p2align 3
.L23:
	movl	$0, %eax
	movq	%r12, %rsi
	subq	(%rbx), %rsi
	movq	%rbp, %rdx
	cmovs	%rax, %rsi
	movq	%r14, %rax
	.p2align 4,,10
	.p2align 3
.L20:
	leaq	(%rdx,%r10), %rdi
	movq	(%rax), %r9
	movq	(%rdi,%r8), %rcx
	addq	%rsi, %rcx
	cmpq	%r9, %rcx
	cmovg	%r9, %rcx
	movq	%rcx, (%rax)
	movq	8(%rdx), %rcx
	movq	(%rdi,%r8), %rdi
	cmpq	%rdi, %rcx
	cmovg	%rdi, %rcx
	addq	$8, %rax
	addq	$8, %rdx
	movq	%rcx, (%rdx)
	cmpq	%r11, %rax
	jne	.L20
	addq	$8, %rbx
	addq	$2480, %rbp
	cmpq	%r13, %rbx
	jne	.L23
	addq	$8, %r13
	addq	$771280, %r14
	subq	$768800, %r10
	addq	$768800, %r8
	addq	$771280, %r11
	cmpq	(%rsp), %r13
	jne	.L19
	movq	24(%rsp), %rbx
.L22:
	movslq	20(%rsp), %rax
	leaq	.LC3(%rip), %rsi
	movl	$1, %edi
	imulq	$96410, %rax, %rax
	addq	8(%rsp), %rax
	movq	(%rbx,%rax,8), %rdx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L40
	addq	$56, %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
.L39:
	.cfi_restore_state
	xorl	%r8d, %r8d
	jmp	.L13
.L7:
	movq	$0, d(%rip)
	leaq	d(%rip), %rbx
.L38:
	movslq	%r11d, %rax
	movq	%rax, 8(%rsp)
	jmp	.L22
.L40:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	main, .-main
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2480
c:
	.zero	2480
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 238328000
d:
	.zero	238328000
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC2:
	.quad	1000000000000000000
	.quad	1000000000000000000
	.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>
long long MAX(long long a,long long b){return a<b?b:a;}
long long MIN(long long a,long long b){return a<b?a:b;}
long long d[310][310][310],c[310]={};
int main(){
  int n,m,i,j,k;
  scanf("%d %d",&n,&m);
  for(i=0;i<n;i++)scanf("%lld",&c[i+1]);
  n++;
  for(i=0;i<=n;i++){
    for(j=0;j<=n;j++){
      for(k=0;k<=m;k++)d[i][j][k]=1e18;
    }
  }
  d[0][0][0]=0;
  for(i=1;i<=n;i++){
    for(j=0;j<=i;j++){
      for(k=0;k<=m;k++){
	d[i][i][k  ]=MIN(d[i][i][k  ],d[i-1][j][k]+MAX(c[i]-c[j],0));
	d[i][j][k+1]=MIN(d[i][j][k+1],d[i-1][j][k]);
      }
    }
  }
  /*for(i=0;i<=n;i++){
    for(j=0;j<=n;j++){
      for(k=0;k<=m;k++)printf("%20lld ",d[i][j][k]);
      printf("\n");
    }
    printf("\n");
    }
    printf("\n");//*/
  printf("%lld\n",d[n][n][m]);
  return 0;
}

10 0
2 1000000000 1 1000000000 1 1000000000 1 1000000000 1 1000000000
 6 2
8 3 9 1 2 1
 10 0
2 1001000000 1 1000000000 1 1000000000 1 1000000000 1 1000000000
 6 2
8 0 9 1 2 1
 10 0
2 1001001000 1 1000000000 1 1000000000 1 1000000000 1 1000000000
 6 4
8 0 9 1 2 1
 4 0
2 5 4 2
 10 0
2 1001001000 1 1000000000 1 1000000000 1 1000000000 2 1000000000
 10 0
2 1001001000 1 1000010000 1 1000000000 1 1000000000 2 1000000000
 10 0
2 1001001000 2 1000010000 1 1000000000 1 1000000000 2 1000000000

4999999996
 4
 5000999996
 2
 5001000996
 1
 5
 5001000995
 5001010995
 5001010994

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>
long long MAX(long long a,long long b){return a<b?b:a;}
long long MIN(long long a,long long b){return a<b?a:b;}
long long d[310][310][310],c[310]={};
int main(){
  int n,m,i,j,k;
  scanf("%d %d",&n,&m);
  for(i=0;i<n;i++)scanf("%lld",&c[i+1]);
  n++;
  for(i=0;i<=n;i++){
    for(j=0;j<=n;j++){
      for(k=0;k<=m;k++)d[i][j][k]=1e18;
    }
  }
  d[0][0][0]=0;
  for(i=1;i<=n;i++){
    for(j=0;j<=i;j++){
      for(k=0;k<=m;k++){
	d[i][i][k  ]=MIN(d[i][i][k  ],d[i-1][j][k]+MAX(c[i]-c[j],0));
	d[i][j][k+1]=MIN(d[i][j][k+1],d[i-1][j][k]);
      }
    }
  }
  /*for(i=0;i<=n;i++){
    for(j=0;j<=n;j++){
      for(k=0;k<=m;k++)printf("%20lld ",d[i][j][k]);
      printf("\n");
    }
    printf("\n");
    }
    printf("\n");//*/
  printf("%lld\n",d[n][n][m]);
  return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	MAX
	.type	MAX, @function
MAX:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-8(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	MAX, .-MAX
	.globl	MIN
	.type	MIN, @function
MIN:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-16(%rbp), %rdx
	movq	-8(%rbp), %rax
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	MIN, .-MIN
	.globl	d
	.bss
	.align 32
	.type	d, @object
	.size	d, 238328000
d:
	.zero	238328000
	.globl	c
	.align 32
	.type	c, @object
	.size	c, 2480
c:
	.zero	2480
	.section	.rodata
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset 3, -24
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	leaq	-40(%rbp), %rdx
	leaq	-44(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -36(%rbp)
	jmp	.L6
.L7:
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	c(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -36(%rbp)
.L6:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jl	.L7
	movl	-44(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -44(%rbp)
	movl	$0, -36(%rbp)
	jmp	.L8
.L13:
	movl	$0, -32(%rbp)
	jmp	.L9
.L12:
	movl	$0, -28(%rbp)
	jmp	.L10
.L11:
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movl	-36(%rbp), %eax
	movslq	%eax, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movabsq	$1000000000000000000, %rbx
	movq	%rbx, (%rdx,%rax)
	addl	$1, -28(%rbp)
.L10:
	movl	-40(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L11
	addl	$1, -32(%rbp)
.L9:
	movl	-44(%rbp), %eax
	cmpl	%eax, -32(%rbp)
	jle	.L12
	addl	$1, -36(%rbp)
.L8:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L13
	movq	$0, d(%rip)
	movl	$1, -36(%rbp)
	jmp	.L14
.L19:
	movl	$0, -32(%rbp)
	jmp	.L15
.L18:
	movl	$0, -28(%rbp)
	jmp	.L16
.L17:
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movslq	%edx, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rbx
	movl	-36(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	c(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-32(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	c(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movl	$0, %esi
	movq	%rax, %rdi
	call	MAX
	leaq	(%rbx,%rax), %rdx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movl	-36(%rbp), %eax
	cltq
	imulq	$96410, %rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rcx
	leaq	d(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	MIN
	movl	-28(%rbp), %edx
	movslq	%edx, %rcx
	movl	-36(%rbp), %edx
	movslq	%edx, %rdx
	imulq	$96410, %rdx, %rdx
	addq	%rcx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	d(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movslq	%edx, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-28(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rsi
	movl	-36(%rbp), %eax
	movslq	%eax, %rcx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rcx, %rcx
	imulq	$310, %rax, %rax
	addq	%rcx, %rax
	addq	%rsi, %rax
	leaq	0(,%rax,8), %rcx
	leaq	d(%rip), %rax
	movq	(%rcx,%rax), %rax
	movl	-28(%rbp), %ecx
	leal	1(%rcx), %ebx
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	MIN
	movslq	%ebx, %rsi
	movl	-36(%rbp), %edx
	movslq	%edx, %rcx
	movl	-32(%rbp), %edx
	movslq	%edx, %rdx
	imulq	$96100, %rcx, %rcx
	imulq	$310, %rdx, %rdx
	addq	%rcx, %rdx
	addq	%rsi, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	d(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addl	$1, -28(%rbp)
.L16:
	movl	-40(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L17
	addl	$1, -32(%rbp)
.L15:
	movl	-32(%rbp), %eax
	cmpl	-36(%rbp), %eax
	jle	.L18
	addl	$1, -36(%rbp)
.L14:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L19
	movl	-44(%rbp), %edx
	movl	-44(%rbp), %eax
	movl	-40(%rbp), %ecx
	movslq	%ecx, %rcx
	movslq	%edx, %rdx
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-24(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L21
	call	__stack_chk_fail@PLT
.L21:
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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	MAX
	.type	MAX, @function
MAX:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-8(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	MAX, .-MAX
	.globl	MIN
	.type	MIN, @function
MIN:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-16(%rbp), %rdx
	movq	-8(%rbp), %rax
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	MIN, .-MIN
	.globl	d
	.bss
	.align 32
	.type	d, @object
	.size	d, 238328000
d:
	.zero	238328000
	.globl	c
	.align 32
	.type	c, @object
	.size	c, 2480
c:
	.zero	2480
	.section	.rodata
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset 3, -24
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	leaq	-40(%rbp), %rdx
	leaq	-44(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -36(%rbp)
	jmp	.L6
.L7:
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	c(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -36(%rbp)
.L6:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jl	.L7
	movl	-44(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -44(%rbp)
	movl	$0, -36(%rbp)
	jmp	.L8
.L13:
	movl	$0, -32(%rbp)
	jmp	.L9
.L12:
	movl	$0, -28(%rbp)
	jmp	.L10
.L11:
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movl	-36(%rbp), %eax
	movslq	%eax, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movabsq	$1000000000000000000, %rbx
	movq	%rbx, (%rdx,%rax)
	addl	$1, -28(%rbp)
.L10:
	movl	-40(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L11
	addl	$1, -32(%rbp)
.L9:
	movl	-44(%rbp), %eax
	cmpl	%eax, -32(%rbp)
	jle	.L12
	addl	$1, -36(%rbp)
.L8:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L13
	movq	$0, d(%rip)
	movl	$1, -36(%rbp)
	jmp	.L14
.L19:
	movl	$0, -32(%rbp)
	jmp	.L15
.L18:
	movl	$0, -28(%rbp)
	jmp	.L16
.L17:
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movslq	%edx, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rbx
	movl	-36(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	c(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-32(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	c(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movl	$0, %esi
	movq	%rax, %rdi
	call	MAX
	leaq	(%rbx,%rax), %rdx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movl	-36(%rbp), %eax
	cltq
	imulq	$96410, %rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rcx
	leaq	d(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	MIN
	movl	-28(%rbp), %edx
	movslq	%edx, %rcx
	movl	-36(%rbp), %edx
	movslq	%edx, %rdx
	imulq	$96410, %rdx, %rdx
	addq	%rcx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	d(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	-28(%rbp), %eax
	movslq	%eax, %rcx
	movslq	%edx, %rdx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-28(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rsi
	movl	-36(%rbp), %eax
	movslq	%eax, %rcx
	movl	-32(%rbp), %eax
	cltq
	imulq	$96100, %rcx, %rcx
	imulq	$310, %rax, %rax
	addq	%rcx, %rax
	addq	%rsi, %rax
	leaq	0(,%rax,8), %rcx
	leaq	d(%rip), %rax
	movq	(%rcx,%rax), %rax
	movl	-28(%rbp), %ecx
	leal	1(%rcx), %ebx
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	MIN
	movslq	%ebx, %rsi
	movl	-36(%rbp), %edx
	movslq	%edx, %rcx
	movl	-32(%rbp), %edx
	movslq	%edx, %rdx
	imulq	$96100, %rcx, %rcx
	imulq	$310, %rdx, %rdx
	addq	%rcx, %rdx
	addq	%rsi, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	d(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addl	$1, -28(%rbp)
.L16:
	movl	-40(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L17
	addl	$1, -32(%rbp)
.L15:
	movl	-32(%rbp), %eax
	cmpl	-36(%rbp), %eax
	jle	.L18
	addl	$1, -36(%rbp)
.L14:
	movl	-44(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L19
	movl	-44(%rbp), %edx
	movl	-44(%rbp), %eax
	movl	-40(%rbp), %ecx
	movslq	%ecx, %rcx
	movslq	%edx, %rdx
	cltq
	imulq	$96100, %rdx, %rdx
	imulq	$310, %rax, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	d(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-24(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L21
	call	__stack_chk_fail@PLT
.L21:
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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:
