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

```c
#include <stdio.h>
#define abs(a) ((a)<0 ? -(a) : (a))
#define min(a, b) ((a)<(b) ? (a) : (b))

int main(){
  int n, k, h[100001], dp[100001];
  scanf("%d %d", &n, &k);
  for(int i=0; i<n; i++){
    scanf("%d", &h[i]);
    dp[i] = 10000*n;
  }
  dp[0] = 0;
  for(int i=1; i<n; i++){
    for(int j=1; (j<=k && i-j>=0); j++){
      dp[i] = min(dp[i], dp[i-j]+abs(h[i]-h[i-j]));
    }
  }

  printf("%d\n", dp[n-1]);
  return 0;
}
	 

```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798768
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1328, %rsp
	.cfi_def_cfa_offset 800096
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 800040(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	16(%rsp), %rbx
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r14
	movq	%rbx, %r13
	leaq	400032(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r13, %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	addq	$4, %r13
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	imull	$10000, %r11d, %eax
	movl	%eax, 0(%rbp,%r12,4)
	addq	$1, %r12
	cmpl	%r12d, %r11d
	jg	.L3
	movl	$0, 400032(%rsp)
	cmpl	$1, %r11d
	jle	.L8
	movl	12(%rsp), %r10d
	testl	%r10d, %r10d
	jle	.L8
	leaq	400036(%rsp), %r8
	xorl	%r12d, %r12d
	movl	$1, %edi
	.p2align 4,,10
	.p2align 3
.L6:
	movl	4(%rbx,%r12,4), %r9d
	movl	(%r8), %ecx
	movq	%r12, %rdx
	addl	$1, %edi
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L7:
	subq	$1, %rdx
	testl	%edx, %edx
	js	.L10
.L9:
	movl	%r9d, %esi
	subl	(%rbx,%rdx,4), %esi
	movl	%esi, %eax
	negl	%eax
	cmovs	%esi, %eax
	addl	0(%rbp,%rdx,4), %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	movl	%edi, %eax
	subl	%edx, %eax
	movl	%ecx, (%r8)
	cmpl	%eax, %r10d
	jge	.L7
.L10:
	addq	$1, %r12
	addq	$4, %r8
	cmpl	%edi, %r11d
	jne	.L6
.L8:
	leal	-1(%r11), %eax
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	cltq
	movl	400032(%rsp,%rax,4), %edx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	800040(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L18
	addq	$800048, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L2:
	.cfi_restore_state
	movl	$0, 400032(%rsp)
	jmp	.L8
.L18:
	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:
```

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	"%d %d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798768
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1328, %rsp
	.cfi_def_cfa_offset 800096
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 800040(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	16(%rsp), %rbx
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r14
	movq	%rbx, %r13
	leaq	400032(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r13, %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	addq	$4, %r13
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	imull	$10000, %r11d, %eax
	movl	%eax, 0(%rbp,%r12,4)
	addq	$1, %r12
	cmpl	%r12d, %r11d
	jg	.L3
	movl	$0, 400032(%rsp)
	cmpl	$1, %r11d
	jle	.L8
	movl	12(%rsp), %r10d
	testl	%r10d, %r10d
	jle	.L8
	leaq	400036(%rsp), %r8
	xorl	%r12d, %r12d
	movl	$1, %edi
	.p2align 4,,10
	.p2align 3
.L6:
	movl	4(%rbx,%r12,4), %r9d
	movl	(%r8), %ecx
	movq	%r12, %rdx
	addl	$1, %edi
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L7:
	subq	$1, %rdx
	testl	%edx, %edx
	js	.L10
.L9:
	movl	%r9d, %esi
	subl	(%rbx,%rdx,4), %esi
	movl	%esi, %eax
	negl	%eax
	cmovs	%esi, %eax
	addl	0(%rbp,%rdx,4), %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	movl	%edi, %eax
	subl	%edx, %eax
	movl	%ecx, (%r8)
	cmpl	%eax, %r10d
	jge	.L7
.L10:
	addq	$1, %r12
	addq	$4, %r8
	cmpl	%edi, %r11d
	jne	.L6
.L8:
	leal	-1(%r11), %eax
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	cltq
	movl	400032(%rsp,%rax,4), %edx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	800040(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L18
	addq	$800048, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L2:
	.cfi_restore_state
	movl	$0, 400032(%rsp)
	jmp	.L8
.L18:
	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
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798768
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1328, %rsp
	.cfi_def_cfa_offset 800096
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 800040(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	16(%rsp), %rbx
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r14
	movq	%rbx, %r13
	leaq	400032(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r13, %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	addq	$4, %r13
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	imull	$10000, %r11d, %eax
	movl	%eax, 0(%rbp,%r12,4)
	addq	$1, %r12
	cmpl	%r12d, %r11d
	jg	.L3
	movl	$0, 400032(%rsp)
	cmpl	$1, %r11d
	jle	.L8
	movl	12(%rsp), %r10d
	testl	%r10d, %r10d
	jle	.L8
	leaq	400036(%rsp), %r8
	xorl	%r12d, %r12d
	movl	$1, %edi
	.p2align 4,,10
	.p2align 3
.L6:
	movl	4(%rbx,%r12,4), %r9d
	movl	(%r8), %ecx
	movq	%r12, %rdx
	addl	$1, %edi
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L7:
	subq	$1, %rdx
	testl	%edx, %edx
	js	.L10
.L9:
	movl	%r9d, %esi
	subl	(%rbx,%rdx,4), %esi
	movl	%esi, %eax
	negl	%eax
	cmovs	%esi, %eax
	addl	0(%rbp,%rdx,4), %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	movl	%edi, %eax
	subl	%edx, %eax
	movl	%ecx, (%r8)
	cmpl	%eax, %r10d
	jge	.L7
.L10:
	addq	$1, %r12
	addq	$4, %r8
	cmpl	%edi, %r11d
	jne	.L6
.L8:
	leal	-1(%r11), %eax
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	cltq
	movl	400032(%rsp,%rax,4), %edx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	800040(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L18
	addq	$800048, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L2:
	.cfi_restore_state
	movl	$0, 400032(%rsp)
	jmp	.L8
.L18:
	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:
```
```c
#include <stdio.h>
#define abs(a) ((a)<0 ? -(a) : (a))
#define min(a, b) ((a)<(b) ? (a) : (b))

int main(){
  int n, k, h[100001], dp[100001];
  scanf("%d %d", &n, &k);
  for(int i=0; i<n; i++){
    scanf("%d", &h[i]);
    dp[i] = 10000*n;
  }
  dp[0] = 0;
  for(int i=1; i<n; i++){
    for(int j=1; (j<=k && i-j>=0); j++){
      dp[i] = min(dp[i], dp[i-j]+abs(h[i]-h[i-j]));
    }
  }

  printf("%d\n", dp[n-1]);
  return 0;
}
	 

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

```c
#include <stdio.h>
#define abs(a) ((a)<0 ? -(a) : (a))
#define min(a, b) ((a)<(b) ? (a) : (b))

int main(){
  int n, k, h[100001], dp[100001];
  scanf("%d %d", &n, &k);
  for(int i=0; i<n; i++){
    scanf("%d", &h[i]);
    dp[i] = 10000*n;
  }
  dp[0] = 0;
  for(int i=1; i<n; i++){
    for(int j=1; (j<=k && i-j>=0); j++){
      dp[i] = min(dp[i], dp[i-j]+abs(h[i]-h[i-j]));
    }
  }

  printf("%d\n", dp[n-1]);
  return 0;
}
	 

```

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:

2 100
10 9
 5 3
10 30 40 50 24
 3 4
40 10 20 70 80 10 20 70 80 60
 3 1
0 20 10
 3 4
40 10 17 70 80 10 20 70 80 60
 2 100
7 10
 10 4
40 9 20 70 80 10 20 70 80 60
 3 1
9 20 10
 2 100
17 9
 3 4
40 10 34 70 80 10 20 70 80 60

1
 26
 20
 30
 23
 3
 40
 21
 8
 6

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

```c
#include <stdio.h>
#define abs(a) ((a)<0 ? -(a) : (a))
#define min(a, b) ((a)<(b) ? (a) : (b))

int main(){
  int n, k, h[100001], dp[100001];
  scanf("%d %d", &n, &k);
  for(int i=0; i<n; i++){
    scanf("%d", &h[i]);
    dp[i] = 10000*n;
  }
  dp[0] = 0;
  for(int i=1; i<n; i++){
    for(int j=1; (j<=k && i-j>=0); j++){
      dp[i] = min(dp[i], dp[i-j]+abs(h[i]-h[i-j]));
    }
  }

  printf("%d\n", dp[n-1]);
  return 0;
}
	 

```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798768
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1328, %rsp
	.cfi_def_cfa_offset 800096
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 800040(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	16(%rsp), %rbx
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r14
	movq	%rbx, %r13
	leaq	400032(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r13, %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	addq	$4, %r13
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	imull	$10000, %r11d, %eax
	movl	%eax, 0(%rbp,%r12,4)
	addq	$1, %r12
	cmpl	%r12d, %r11d
	jg	.L3
	movl	$0, 400032(%rsp)
	cmpl	$1, %r11d
	jle	.L8
	movl	12(%rsp), %r10d
	testl	%r10d, %r10d
	jle	.L8
	leaq	400036(%rsp), %r8
	xorl	%r12d, %r12d
	movl	$1, %edi
	.p2align 4,,10
	.p2align 3
.L6:
	movl	4(%rbx,%r12,4), %r9d
	movl	(%r8), %ecx
	movq	%r12, %rdx
	addl	$1, %edi
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L7:
	subq	$1, %rdx
	testl	%edx, %edx
	js	.L10
.L9:
	movl	%r9d, %esi
	subl	(%rbx,%rdx,4), %esi
	movl	%esi, %eax
	negl	%eax
	cmovs	%esi, %eax
	addl	0(%rbp,%rdx,4), %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	movl	%edi, %eax
	subl	%edx, %eax
	movl	%ecx, (%r8)
	cmpl	%eax, %r10d
	jge	.L7
.L10:
	addq	$1, %r12
	addq	$4, %r8
	cmpl	%edi, %r11d
	jne	.L6
.L8:
	leal	-1(%r11), %eax
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	cltq
	movl	400032(%rsp,%rax,4), %edx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	800040(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L18
	addq	$800048, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L2:
	.cfi_restore_state
	movl	$0, 400032(%rsp)
	jmp	.L8
.L18:
	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:
```

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	"%d %d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798768
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1328, %rsp
	.cfi_def_cfa_offset 800096
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 800040(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	16(%rsp), %rbx
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r14
	movq	%rbx, %r13
	leaq	400032(%rsp), %rbp
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r13, %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	addq	$4, %r13
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %r11d
	imull	$10000, %r11d, %eax
	movl	%eax, 0(%rbp,%r12,4)
	addq	$1, %r12
	cmpl	%r12d, %r11d
	jg	.L3
	movl	$0, 400032(%rsp)
	cmpl	$1, %r11d
	jle	.L8
	movl	12(%rsp), %r10d
	testl	%r10d, %r10d
	jle	.L8
	leaq	400036(%rsp), %r8
	xorl	%r12d, %r12d
	movl	$1, %edi
	.p2align 4,,10
	.p2align 3
.L6:
	movl	4(%rbx,%r12,4), %r9d
	movl	(%r8), %ecx
	movq	%r12, %rdx
	addl	$1, %edi
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L7:
	subq	$1, %rdx
	testl	%edx, %edx
	js	.L10
.L9:
	movl	%r9d, %esi
	subl	(%rbx,%rdx,4), %esi
	movl	%esi, %eax
	negl	%eax
	cmovs	%esi, %eax
	addl	0(%rbp,%rdx,4), %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	movl	%edi, %eax
	subl	%edx, %eax
	movl	%ecx, (%r8)
	cmpl	%eax, %r10d
	jge	.L7
.L10:
	addq	$1, %r12
	addq	$4, %r8
	cmpl	%edi, %r11d
	jne	.L6
.L8:
	leal	-1(%r11), %eax
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	cltq
	movl	400032(%rsp,%rax,4), %edx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	800040(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L18
	addq	$800048, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L2:
	.cfi_restore_state
	movl	$0, 400032(%rsp)
	jmp	.L8
.L18:
	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:
```