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

```c
// Aizu 0270: Modular Query
// 2017.8.24 bal4u@uu

#include <stdio.h>

char tbl[300005];

int main()
{
	int N, Q, i, k, q, max;

	scanf("%d%d", &N, &Q);
	max = 0; while (N-- > 0) {
		scanf("%d", &k), tbl[k] = 1;
		if (k > max) max = k;
		if (k & 1) tbl[1] = 1;
		else tbl[2] = 1;
	}
	while (Q-- > 0) {
		scanf("%d", &q);
		for (k = q-1; ; k--) {
			for (i = k; i <= max; i += q)
				if (tbl[i]) { printf("%d\n", k), k = 0; goto Done; }
		}
		Done:;
	}
	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
	leaq	.LC0(%rip), %rdi
	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
	xorl	%ebx, %ebx
	subq	$32, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
	leaq	16(%rsp), %r13
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L26:
	movl	8(%rsp), %eax
	movb	$1, 1+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
.L5:
	xorl	%eax, %eax
	movq	%r13, %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rdx
	cmpl	%edx, %ebx
	movq	%rdx, %rax
	movb	$1, 0(%rbp,%rdx)
	cmovl	%edx, %ebx
	testb	$1, %al
	jne	.L26
	movl	8(%rsp), %eax
	movb	$1, 2+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jg	.L5
.L2:
	movl	12(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jle	.L6
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	leaq	20(%rsp), %r13
	leaq	.LC2(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L12:
	movq	%r13, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	20(%rsp), %rdx
	leal	-1(%rdx), %eax
	movl	%eax, 16(%rsp)
	cmpl	$1, %edx
	jne	.L27
	xorl	%ecx, %ecx
	xorl	%edx, %edx
	xorl	%esi, %esi
.L7:
	movl	%edx, %r8d
	cmpl	%ebx, %edx
	jg	.L15
	movq	%rcx, %rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L28:
	addq	$1, %rax
	cmpl	%eax, %ebx
	jl	.L15
.L17:
	cmpb	$0, 0(%rbp,%rax)
	je	.L28
.L16:
	testb	%sil, %sil
	je	.L10
	movl	%r8d, 16(%rsp)
.L10:
	movl	%r8d, %edx
	movq	%r14, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	12(%rsp), %eax
	movl	$0, 16(%rsp)
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jg	.L12
.L6:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L29
	addq	$32, %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
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	subl	$1, %edx
	subq	$1, %rcx
	movl	$1, %esi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L27:
	movslq	%eax, %rdi
	xorl	%esi, %esi
	movq	%rdi, %rcx
.L14:
	movl	%ecx, %r8d
	cmpl	%ebx, %ecx
	jg	.L8
	movq	%rdi, %rax
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L9:
	addq	%rdx, %rax
	cmpl	%eax, %ebx
	jl	.L8
.L13:
	cmpb	$0, 0(%rbp,%rax)
	je	.L9
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %ecx
	subq	$1, %rdi
	movl	$1, %esi
	jmp	.L14
.L29:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 300005
tbl:
	.zero	300005
	.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
	leaq	.LC0(%rip), %rdi
	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
	xorl	%ebx, %ebx
	subq	$32, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
	leaq	16(%rsp), %r13
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L26:
	movl	8(%rsp), %eax
	movb	$1, 1+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
.L5:
	xorl	%eax, %eax
	movq	%r13, %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rdx
	cmpl	%edx, %ebx
	movq	%rdx, %rax
	movb	$1, 0(%rbp,%rdx)
	cmovl	%edx, %ebx
	testb	$1, %al
	jne	.L26
	movl	8(%rsp), %eax
	movb	$1, 2+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jg	.L5
.L2:
	movl	12(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jle	.L6
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	leaq	20(%rsp), %r13
	leaq	.LC2(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L12:
	movq	%r13, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	20(%rsp), %rdx
	leal	-1(%rdx), %eax
	movl	%eax, 16(%rsp)
	cmpl	$1, %edx
	jne	.L27
	xorl	%ecx, %ecx
	xorl	%edx, %edx
	xorl	%esi, %esi
.L7:
	movl	%edx, %r8d
	cmpl	%ebx, %edx
	jg	.L15
	movq	%rcx, %rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L28:
	addq	$1, %rax
	cmpl	%eax, %ebx
	jl	.L15
.L17:
	cmpb	$0, 0(%rbp,%rax)
	je	.L28
.L16:
	testb	%sil, %sil
	je	.L10
	movl	%r8d, 16(%rsp)
.L10:
	movl	%r8d, %edx
	movq	%r14, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	12(%rsp), %eax
	movl	$0, 16(%rsp)
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jg	.L12
.L6:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L29
	addq	$32, %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
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	subl	$1, %edx
	subq	$1, %rcx
	movl	$1, %esi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L27:
	movslq	%eax, %rdi
	xorl	%esi, %esi
	movq	%rdi, %rcx
.L14:
	movl	%ecx, %r8d
	cmpl	%ebx, %ecx
	jg	.L8
	movq	%rdi, %rax
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L9:
	addq	%rdx, %rax
	cmpl	%eax, %ebx
	jl	.L8
.L13:
	cmpb	$0, 0(%rbp,%rax)
	je	.L9
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %ecx
	subq	$1, %rdi
	movl	$1, %esi
	jmp	.L14
.L29:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 300005
tbl:
	.zero	300005
	.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
	leaq	.LC0(%rip), %rdi
	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
	xorl	%ebx, %ebx
	subq	$32, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
	leaq	16(%rsp), %r13
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L26:
	movl	8(%rsp), %eax
	movb	$1, 1+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
.L5:
	xorl	%eax, %eax
	movq	%r13, %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rdx
	cmpl	%edx, %ebx
	movq	%rdx, %rax
	movb	$1, 0(%rbp,%rdx)
	cmovl	%edx, %ebx
	testb	$1, %al
	jne	.L26
	movl	8(%rsp), %eax
	movb	$1, 2+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jg	.L5
.L2:
	movl	12(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jle	.L6
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	leaq	20(%rsp), %r13
	leaq	.LC2(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L12:
	movq	%r13, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	20(%rsp), %rdx
	leal	-1(%rdx), %eax
	movl	%eax, 16(%rsp)
	cmpl	$1, %edx
	jne	.L27
	xorl	%ecx, %ecx
	xorl	%edx, %edx
	xorl	%esi, %esi
.L7:
	movl	%edx, %r8d
	cmpl	%ebx, %edx
	jg	.L15
	movq	%rcx, %rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L28:
	addq	$1, %rax
	cmpl	%eax, %ebx
	jl	.L15
.L17:
	cmpb	$0, 0(%rbp,%rax)
	je	.L28
.L16:
	testb	%sil, %sil
	je	.L10
	movl	%r8d, 16(%rsp)
.L10:
	movl	%r8d, %edx
	movq	%r14, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	12(%rsp), %eax
	movl	$0, 16(%rsp)
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jg	.L12
.L6:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L29
	addq	$32, %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
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	subl	$1, %edx
	subq	$1, %rcx
	movl	$1, %esi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L27:
	movslq	%eax, %rdi
	xorl	%esi, %esi
	movq	%rdi, %rcx
.L14:
	movl	%ecx, %r8d
	cmpl	%ebx, %ecx
	jg	.L8
	movq	%rdi, %rax
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L9:
	addq	%rdx, %rax
	cmpl	%eax, %ebx
	jl	.L8
.L13:
	cmpb	$0, 0(%rbp,%rax)
	je	.L9
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %ecx
	subq	$1, %rdi
	movl	$1, %esi
	jmp	.L14
.L29:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 300005
tbl:
	.zero	300005
	.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
// Aizu 0270: Modular Query
// 2017.8.24 bal4u@uu

#include <stdio.h>

char tbl[300005];

int main()
{
	int N, Q, i, k, q, max;

	scanf("%d%d", &N, &Q);
	max = 0; while (N-- > 0) {
		scanf("%d", &k), tbl[k] = 1;
		if (k > max) max = k;
		if (k & 1) tbl[1] = 1;
		else tbl[2] = 1;
	}
	while (Q-- > 0) {
		scanf("%d", &q);
		for (k = q-1; ; k--) {
			for (i = k; i <= max; i += q)
				if (tbl[i]) { printf("%d\n", k), k = 0; goto Done; }
		}
		Done:;
	}
	return 0;
}```
Given the following C code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
// Aizu 0270: Modular Query
// 2017.8.24 bal4u@uu

#include <stdio.h>

char tbl[300005];

int main()
{
	int N, Q, i, k, q, max;

	scanf("%d%d", &N, &Q);
	max = 0; while (N-- > 0) {
		scanf("%d", &k), tbl[k] = 1;
		if (k > max) max = k;
		if (k & 1) tbl[1] = 1;
		else tbl[2] = 1;
	}
	while (Q-- > 0) {
		scanf("%d", &q);
		for (k = q-1; ; k--) {
			for (i = k; i <= max; i += q)
				if (tbl[i]) { printf("%d\n", k), k = 0; goto Done; }
		}
		Done:;
	}
	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:

3 3
9 3 8
6
6
5
 3 3
9 3 10
6
6
5
 3 3
9 3 8
4
6
3
 3 3
9 3 8
6
6
2
 3 2
1 3 8
4
6
3
 3 3
9 2 8
4
6
5
 3 3
12 3 8
6
6
5
 3 3
9 3 8
4
6
1
 3 3
9 3 8
12
6
2
 3 2
1 3 11
4
6
3

3
3
4
 4
4
4
 3
3
2
 3
3
1
 3
3
 2
3
4
 3
3
3
 3
3
0
 9
3
1
 3
5

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

```c
// Aizu 0270: Modular Query
// 2017.8.24 bal4u@uu

#include <stdio.h>

char tbl[300005];

int main()
{
	int N, Q, i, k, q, max;

	scanf("%d%d", &N, &Q);
	max = 0; while (N-- > 0) {
		scanf("%d", &k), tbl[k] = 1;
		if (k > max) max = k;
		if (k & 1) tbl[1] = 1;
		else tbl[2] = 1;
	}
	while (Q-- > 0) {
		scanf("%d", &q);
		for (k = q-1; ; k--) {
			for (i = k; i <= max; i += q)
				if (tbl[i]) { printf("%d\n", k), k = 0; goto Done; }
		}
		Done:;
	}
	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
	leaq	.LC0(%rip), %rdi
	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
	xorl	%ebx, %ebx
	subq	$32, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
	leaq	16(%rsp), %r13
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L26:
	movl	8(%rsp), %eax
	movb	$1, 1+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
.L5:
	xorl	%eax, %eax
	movq	%r13, %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rdx
	cmpl	%edx, %ebx
	movq	%rdx, %rax
	movb	$1, 0(%rbp,%rdx)
	cmovl	%edx, %ebx
	testb	$1, %al
	jne	.L26
	movl	8(%rsp), %eax
	movb	$1, 2+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jg	.L5
.L2:
	movl	12(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jle	.L6
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	leaq	20(%rsp), %r13
	leaq	.LC2(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L12:
	movq	%r13, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	20(%rsp), %rdx
	leal	-1(%rdx), %eax
	movl	%eax, 16(%rsp)
	cmpl	$1, %edx
	jne	.L27
	xorl	%ecx, %ecx
	xorl	%edx, %edx
	xorl	%esi, %esi
.L7:
	movl	%edx, %r8d
	cmpl	%ebx, %edx
	jg	.L15
	movq	%rcx, %rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L28:
	addq	$1, %rax
	cmpl	%eax, %ebx
	jl	.L15
.L17:
	cmpb	$0, 0(%rbp,%rax)
	je	.L28
.L16:
	testb	%sil, %sil
	je	.L10
	movl	%r8d, 16(%rsp)
.L10:
	movl	%r8d, %edx
	movq	%r14, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	12(%rsp), %eax
	movl	$0, 16(%rsp)
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jg	.L12
.L6:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L29
	addq	$32, %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
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	subl	$1, %edx
	subq	$1, %rcx
	movl	$1, %esi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L27:
	movslq	%eax, %rdi
	xorl	%esi, %esi
	movq	%rdi, %rcx
.L14:
	movl	%ecx, %r8d
	cmpl	%ebx, %ecx
	jg	.L8
	movq	%rdi, %rax
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L9:
	addq	%rdx, %rax
	cmpl	%eax, %ebx
	jl	.L8
.L13:
	cmpb	$0, 0(%rbp,%rax)
	je	.L9
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %ecx
	subq	$1, %rdi
	movl	$1, %esi
	jmp	.L14
.L29:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 300005
tbl:
	.zero	300005
	.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
	leaq	.LC0(%rip), %rdi
	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
	xorl	%ebx, %ebx
	subq	$32, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	leaq	8(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
	leaq	16(%rsp), %r13
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L26:
	movl	8(%rsp), %eax
	movb	$1, 1+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jle	.L2
.L5:
	xorl	%eax, %eax
	movq	%r13, %rsi
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rdx
	cmpl	%edx, %ebx
	movq	%rdx, %rax
	movb	$1, 0(%rbp,%rdx)
	cmovl	%edx, %ebx
	testb	$1, %al
	jne	.L26
	movl	8(%rsp), %eax
	movb	$1, 2+tbl(%rip)
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jg	.L5
.L2:
	movl	12(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jle	.L6
	leaq	.LC1(%rip), %r12
	leaq	tbl(%rip), %rbp
	leaq	20(%rsp), %r13
	leaq	.LC2(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L12:
	movq	%r13, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	20(%rsp), %rdx
	leal	-1(%rdx), %eax
	movl	%eax, 16(%rsp)
	cmpl	$1, %edx
	jne	.L27
	xorl	%ecx, %ecx
	xorl	%edx, %edx
	xorl	%esi, %esi
.L7:
	movl	%edx, %r8d
	cmpl	%ebx, %edx
	jg	.L15
	movq	%rcx, %rax
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L28:
	addq	$1, %rax
	cmpl	%eax, %ebx
	jl	.L15
.L17:
	cmpb	$0, 0(%rbp,%rax)
	je	.L28
.L16:
	testb	%sil, %sil
	je	.L10
	movl	%r8d, 16(%rsp)
.L10:
	movl	%r8d, %edx
	movq	%r14, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	12(%rsp), %eax
	movl	$0, 16(%rsp)
	leal	-1(%rax), %edx
	movl	%edx, 12(%rsp)
	testl	%eax, %eax
	jg	.L12
.L6:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L29
	addq	$32, %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
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	subl	$1, %edx
	subq	$1, %rcx
	movl	$1, %esi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L27:
	movslq	%eax, %rdi
	xorl	%esi, %esi
	movq	%rdi, %rcx
.L14:
	movl	%ecx, %r8d
	cmpl	%ebx, %ecx
	jg	.L8
	movq	%rdi, %rax
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L9:
	addq	%rdx, %rax
	cmpl	%eax, %ebx
	jl	.L8
.L13:
	cmpb	$0, 0(%rbp,%rax)
	je	.L9
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %ecx
	subq	$1, %rdi
	movl	$1, %esi
	jmp	.L14
.L29:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 300005
tbl:
	.zero	300005
	.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:
```