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

```c
m,t,pre,ans,h,i,a,j;
main(n){
	for(;scanf("%d%d",&n,&m)*n;){
		t=1e6;
		h=0;
		pre=0;
		for(i=0;i<n;i++){
			scanf("%d",&a);
			j=m/a*a;
			if(j*2000+a<=t*2000+pre){
				h=j*2000+a==t*2000+pre;
				t=j;
				pre=a;
				ans=i;
			}
		}
		printf("%d\n",h?n:ans+1);
	}
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	m
	.bss
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	t
	.align 4
	.type	t, @object
	.size	t, 4
t:
	.zero	4
	.globl	pre
	.align 4
	.type	pre, @object
	.size	pre, 4
pre:
	.zero	4
	.globl	ans
	.align 4
	.type	ans, @object
	.size	ans, 4
ans:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	i
	.align 4
	.type	i, @object
	.size	i, 4
i:
	.zero	4
	.globl	a
	.align 4
	.type	a, @object
	.size	a, 4
a:
	.zero	4
	.globl	j
	.align 4
	.type	j, @object
	.size	j, 4
j:
	.zero	4
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d%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
	subq	$16, %rsp
	movl	%edi, -4(%rbp)
	jmp	.L2
.L8:
	movl	$1000000, t(%rip)
	movl	$0, h(%rip)
	movl	$0, pre(%rip)
	movl	$0, i(%rip)
	jmp	.L3
.L5:
	leaq	a(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	scanf@PLT
	movl	m(%rip), %eax
	movl	a(%rip), %esi
	cltd
	idivl	%esi
	movl	%eax, %edx
	movl	a(%rip), %eax
	imull	%edx, %eax
	movl	%eax, j(%rip)
	movl	j(%rip), %eax
	imull	$2000, %eax, %edx
	movl	a(%rip), %eax
	addl	%eax, %edx
	movl	t(%rip), %eax
	imull	$2000, %eax, %ecx
	movl	pre(%rip), %eax
	addl	%ecx, %eax
	cmpl	%eax, %edx
	jg	.L4
	movl	j(%rip), %eax
	imull	$2000, %eax, %edx
	movl	a(%rip), %eax
	addl	%eax, %edx
	movl	t(%rip), %eax
	imull	$2000, %eax, %ecx
	movl	pre(%rip), %eax
	addl	%ecx, %eax
	cmpl	%eax, %edx
	sete	%al
	movzbl	%al, %eax
	movl	%eax, h(%rip)
	movl	j(%rip), %eax
	movl	%eax, t(%rip)
	movl	a(%rip), %eax
	movl	%eax, pre(%rip)
	movl	i(%rip), %eax
	movl	%eax, ans(%rip)
.L4:
	movl	i(%rip), %eax
	addl	$1, %eax
	movl	%eax, i(%rip)
.L3:
	movl	i(%rip), %edx
	movl	-4(%rbp), %eax
	cmpl	%eax, %edx
	jl	.L5
	movl	h(%rip), %eax
	testl	%eax, %eax
	jne	.L6
	movl	ans(%rip), %eax
	addl	$1, %eax
	jmp	.L7
.L6:
	movl	-4(%rbp), %eax
.L7:
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L2:
	leaq	-4(%rbp), %rax
	leaq	m(%rip), %rdx
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	scanf@PLT
	movl	-4(%rbp), %edx
	imull	%edx, %eax
	testl	%eax, %eax
	jne	.L8
	movl	$0, %eax
	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"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC1(%rip), %r15
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	m(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	leaq	.LC2(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	a(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	.LC0(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movl	%edi, 12(%rsp)
	leaq	12(%rsp), %r14
	.p2align 4,,10
	.p2align 3
.L2:
	movq	%r13, %rdx
	movq	%r14, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	scanf@PLT
	movl	12(%rsp), %edx
	imull	%edx, %eax
	testl	%eax, %eax
	je	.L14
	movl	$1000000, t(%rip)
	movl	$0, h(%rip)
	movl	$0, pre(%rip)
	movl	$0, i(%rip)
	testl	%edx, %edx
	jle	.L8
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rbp, %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	call	scanf@PLT
	movl	m(%rip), %eax
	movl	a(%rip), %ecx
	cltd
	idivl	%ecx
	imull	$2000, t(%rip), %edx
	addl	pre(%rip), %edx
	imull	%ecx, %eax
	imull	$2000, %eax, %esi
	movl	%eax, j(%rip)
	addl	%ecx, %esi
	cmpl	%edx, %esi
	jle	.L5
	movl	i(%rip), %eax
	movl	12(%rsp), %esi
	addl	$1, %eax
	movl	%eax, i(%rip)
	cmpl	%eax, %esi
	jg	.L3
	movl	h(%rip), %eax
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r15, %rdi
	xorl	%eax, %eax
	call	printf@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L5:
	movl	%eax, t(%rip)
	movl	i(%rip), %eax
	sete	%dl
	movl	12(%rsp), %esi
	movzbl	%dl, %edx
	movl	%ecx, pre(%rip)
	movl	%eax, ans(%rip)
	addl	$1, %eax
	movl	%edx, h(%rip)
	movl	%eax, i(%rip)
	cmpl	%esi, %eax
	jl	.L3
	movl	h(%rip), %eax
	testl	%eax, %eax
	jne	.L4
.L8:
	movl	ans(%rip), %eax
	leal	1(%rax), %esi
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L14:
	addq	$24, %rsp
	.cfi_def_cfa_offset 56
	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
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.globl	j
	.bss
	.align 4
	.type	j, @object
	.size	j, 4
j:
	.zero	4
	.globl	a
	.align 4
	.type	a, @object
	.size	a, 4
a:
	.zero	4
	.globl	i
	.align 4
	.type	i, @object
	.size	i, 4
i:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	ans
	.align 4
	.type	ans, @object
	.size	ans, 4
ans:
	.zero	4
	.globl	pre
	.align 4
	.type	pre, @object
	.size	pre, 4
pre:
	.zero	4
	.globl	t
	.align 4
	.type	t, @object
	.size	t, 4
t:
	.zero	4
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.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	"%d\n"
.LC2:
	.string	"%d%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC1(%rip), %r15
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	m(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	leaq	.LC2(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	a(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	.LC0(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movl	%edi, 12(%rsp)
	leaq	12(%rsp), %r14
	.p2align 4,,10
	.p2align 3
.L2:
	movq	%r13, %rdx
	movq	%r14, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	scanf@PLT
	movl	12(%rsp), %edx
	imull	%edx, %eax
	testl	%eax, %eax
	je	.L14
	movl	$1000000, t(%rip)
	movl	$0, h(%rip)
	movl	$0, pre(%rip)
	movl	$0, i(%rip)
	testl	%edx, %edx
	jle	.L8
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rbp, %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	call	scanf@PLT
	movl	m(%rip), %eax
	movl	a(%rip), %ecx
	cltd
	idivl	%ecx
	imull	$2000, t(%rip), %edx
	addl	pre(%rip), %edx
	imull	%ecx, %eax
	imull	$2000, %eax, %esi
	movl	%eax, j(%rip)
	addl	%ecx, %esi
	cmpl	%edx, %esi
	jle	.L5
	movl	i(%rip), %eax
	movl	12(%rsp), %esi
	addl	$1, %eax
	movl	%eax, i(%rip)
	cmpl	%eax, %esi
	jg	.L3
	movl	h(%rip), %eax
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r15, %rdi
	xorl	%eax, %eax
	call	printf@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L5:
	movl	%eax, t(%rip)
	movl	i(%rip), %eax
	sete	%dl
	movl	12(%rsp), %esi
	movzbl	%dl, %edx
	movl	%ecx, pre(%rip)
	movl	%eax, ans(%rip)
	addl	$1, %eax
	movl	%edx, h(%rip)
	movl	%eax, i(%rip)
	cmpl	%esi, %eax
	jl	.L3
	movl	h(%rip), %eax
	testl	%eax, %eax
	jne	.L4
.L8:
	movl	ans(%rip), %eax
	leal	1(%rax), %esi
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L14:
	addq	$24, %rsp
	.cfi_def_cfa_offset 56
	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
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.globl	j
	.bss
	.align 4
	.type	j, @object
	.size	j, 4
j:
	.zero	4
	.globl	a
	.align 4
	.type	a, @object
	.size	a, 4
a:
	.zero	4
	.globl	i
	.align 4
	.type	i, @object
	.size	i, 4
i:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	ans
	.align 4
	.type	ans, @object
	.size	ans, 4
ans:
	.zero	4
	.globl	pre
	.align 4
	.type	pre, @object
	.size	pre, 4
pre:
	.zero	4
	.globl	t
	.align 4
	.type	t, @object
	.size	t, 4
t:
	.zero	4
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.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:

m,t,pre,ans,h,i,a,j;
main(n){
	for(;scanf("%d%d",&n,&m)*n;){
		t=1e6;
		h=0;
		pre=0;
		for(i=0;i<n;i++){
			scanf("%d",&a);
			j=m/a*a;
			if(j*2000+a<=t*2000+pre){
				h=j*2000+a==t*2000+pre;
				t=j;
				pre=a;
				ans=i;
			}
		}
		printf("%d\n",h?n:ans+1);
	}
}
3 101
3 7 4
5 24
4 6 12 3 8
5 1
1 1 2 2 3
0 0
 3 101
3 7 4
5 24
4 5 12 3 8
5 1
1 1 2 2 3
0 0
 3 101
1 7 7
5 24
4 5 12 4 8
5 1
1 1 2 2 3
0 0
 3 100
3 7 4
5 6
4 6 12 3 8
5 1
1 1 2 2 3
0 0
 3 101
1 7 4
5 24
4 5 12 3 8
5 1
1 1 4 2 3
0 0
 3 101
1 7 4
5 24
4 5 12 4 8
5 1
1 1 2 3 3
0 0
 3 111
3 7 4
5 43
4 6 12 3 8
5 1
1 1 2 2 3
0 0
 3 101
1 7 7
5 24
4 5 12 4 8
5 1
1 1 3 2 6
0 0
 3 110
5 7 3
5 43
4 7 12 3 8
5 1
1 1 2 4 3
0 0
 3 100
3 7 8
5 6
1 6 21 6 8
5 1
2 2 2 2 3
0 0

2
4
5
 2
2
5
 3
2
5
 2
5
5
 2
2
4
 2
2
3
 2
3
5
 3
2
4
 2
3
3
 3
5
5

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

```c
m,t,pre,ans,h,i,a,j;
main(n){
	for(;scanf("%d%d",&n,&m)*n;){
		t=1e6;
		h=0;
		pre=0;
		for(i=0;i<n;i++){
			scanf("%d",&a);
			j=m/a*a;
			if(j*2000+a<=t*2000+pre){
				h=j*2000+a==t*2000+pre;
				t=j;
				pre=a;
				ans=i;
			}
		}
		printf("%d\n",h?n:ans+1);
	}
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	m
	.bss
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	t
	.align 4
	.type	t, @object
	.size	t, 4
t:
	.zero	4
	.globl	pre
	.align 4
	.type	pre, @object
	.size	pre, 4
pre:
	.zero	4
	.globl	ans
	.align 4
	.type	ans, @object
	.size	ans, 4
ans:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	i
	.align 4
	.type	i, @object
	.size	i, 4
i:
	.zero	4
	.globl	a
	.align 4
	.type	a, @object
	.size	a, 4
a:
	.zero	4
	.globl	j
	.align 4
	.type	j, @object
	.size	j, 4
j:
	.zero	4
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d%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
	subq	$16, %rsp
	movl	%edi, -4(%rbp)
	jmp	.L2
.L8:
	movl	$1000000, t(%rip)
	movl	$0, h(%rip)
	movl	$0, pre(%rip)
	movl	$0, i(%rip)
	jmp	.L3
.L5:
	leaq	a(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	scanf@PLT
	movl	m(%rip), %eax
	movl	a(%rip), %esi
	cltd
	idivl	%esi
	movl	%eax, %edx
	movl	a(%rip), %eax
	imull	%edx, %eax
	movl	%eax, j(%rip)
	movl	j(%rip), %eax
	imull	$2000, %eax, %edx
	movl	a(%rip), %eax
	addl	%eax, %edx
	movl	t(%rip), %eax
	imull	$2000, %eax, %ecx
	movl	pre(%rip), %eax
	addl	%ecx, %eax
	cmpl	%eax, %edx
	jg	.L4
	movl	j(%rip), %eax
	imull	$2000, %eax, %edx
	movl	a(%rip), %eax
	addl	%eax, %edx
	movl	t(%rip), %eax
	imull	$2000, %eax, %ecx
	movl	pre(%rip), %eax
	addl	%ecx, %eax
	cmpl	%eax, %edx
	sete	%al
	movzbl	%al, %eax
	movl	%eax, h(%rip)
	movl	j(%rip), %eax
	movl	%eax, t(%rip)
	movl	a(%rip), %eax
	movl	%eax, pre(%rip)
	movl	i(%rip), %eax
	movl	%eax, ans(%rip)
.L4:
	movl	i(%rip), %eax
	addl	$1, %eax
	movl	%eax, i(%rip)
.L3:
	movl	i(%rip), %edx
	movl	-4(%rbp), %eax
	cmpl	%eax, %edx
	jl	.L5
	movl	h(%rip), %eax
	testl	%eax, %eax
	jne	.L6
	movl	ans(%rip), %eax
	addl	$1, %eax
	jmp	.L7
.L6:
	movl	-4(%rbp), %eax
.L7:
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L2:
	leaq	-4(%rbp), %rax
	leaq	m(%rip), %rdx
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	scanf@PLT
	movl	-4(%rbp), %edx
	imull	%edx, %eax
	testl	%eax, %eax
	jne	.L8
	movl	$0, %eax
	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
	.globl	m
	.bss
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	t
	.align 4
	.type	t, @object
	.size	t, 4
t:
	.zero	4
	.globl	pre
	.align 4
	.type	pre, @object
	.size	pre, 4
pre:
	.zero	4
	.globl	ans
	.align 4
	.type	ans, @object
	.size	ans, 4
ans:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	i
	.align 4
	.type	i, @object
	.size	i, 4
i:
	.zero	4
	.globl	a
	.align 4
	.type	a, @object
	.size	a, 4
a:
	.zero	4
	.globl	j
	.align 4
	.type	j, @object
	.size	j, 4
j:
	.zero	4
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d%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
	subq	$16, %rsp
	movl	%edi, -4(%rbp)
	jmp	.L2
.L8:
	movl	$1000000, t(%rip)
	movl	$0, h(%rip)
	movl	$0, pre(%rip)
	movl	$0, i(%rip)
	jmp	.L3
.L5:
	leaq	a(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	scanf@PLT
	movl	m(%rip), %eax
	movl	a(%rip), %esi
	cltd
	idivl	%esi
	movl	%eax, %edx
	movl	a(%rip), %eax
	imull	%edx, %eax
	movl	%eax, j(%rip)
	movl	j(%rip), %eax
	imull	$2000, %eax, %edx
	movl	a(%rip), %eax
	addl	%eax, %edx
	movl	t(%rip), %eax
	imull	$2000, %eax, %ecx
	movl	pre(%rip), %eax
	addl	%ecx, %eax
	cmpl	%eax, %edx
	jg	.L4
	movl	j(%rip), %eax
	imull	$2000, %eax, %edx
	movl	a(%rip), %eax
	addl	%eax, %edx
	movl	t(%rip), %eax
	imull	$2000, %eax, %ecx
	movl	pre(%rip), %eax
	addl	%ecx, %eax
	cmpl	%eax, %edx
	sete	%al
	movzbl	%al, %eax
	movl	%eax, h(%rip)
	movl	j(%rip), %eax
	movl	%eax, t(%rip)
	movl	a(%rip), %eax
	movl	%eax, pre(%rip)
	movl	i(%rip), %eax
	movl	%eax, ans(%rip)
.L4:
	movl	i(%rip), %eax
	addl	$1, %eax
	movl	%eax, i(%rip)
.L3:
	movl	i(%rip), %edx
	movl	-4(%rbp), %eax
	cmpl	%eax, %edx
	jl	.L5
	movl	h(%rip), %eax
	testl	%eax, %eax
	jne	.L6
	movl	ans(%rip), %eax
	addl	$1, %eax
	jmp	.L7
.L6:
	movl	-4(%rbp), %eax
.L7:
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L2:
	leaq	-4(%rbp), %rax
	leaq	m(%rip), %rdx
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	scanf@PLT
	movl	-4(%rbp), %edx
	imull	%edx, %eax
	testl	%eax, %eax
	jne	.L8
	movl	$0, %eax
	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:
