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>
struct change{
	char c;
	char newC;
};
struct change c[1000];
int main(){
	int n,i,j,k,m,count;
	char str,tc;
	while(1){
		scanf("%d",&m);
		if(!m)break;
		for(i=0;i<m;i++){
			count=0;
			while(1){
				scanf("%c",&str);
				if(('a'<= str && str <='z') || ('A'<= str && str <='Z')||('0'<= str && str <='9')){
					if(count==0){
						c[i].c=str;count++;
					}
					else{
						c[i].newC=str;
						break;
					}
				}
			}
		}
		scanf("%d",&n);
		for(i=0;i<n;i++){
			while(1){
				scanf("%c",&str);
				if(('a'<= str && str <='z') || ('A'<= str && str <='Z')||('0'<= str && str <='9')){
					tc=str;
					break;
				}
			}
			for(j=0;j<m;j++)
				if(c[j].c==tc){tc=c[j].newC;break;}
			printf("%c",tc);
		}
		printf("\n");
	}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2000
c:
	.zero	2000
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%c"
	.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	$32, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
.L24:
	leaq	-24(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-24(%rbp), %eax
	testl	%eax, %eax
	je	.L29
	movl	$0, -20(%rbp)
	jmp	.L4
.L12:
	movl	$0, -12(%rbp)
.L11:
	leaq	-30(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movzbl	-30(%rbp), %eax
	cmpb	$96, %al
	jle	.L5
	movzbl	-30(%rbp), %eax
	cmpb	$122, %al
	jle	.L6
.L5:
	movzbl	-30(%rbp), %eax
	cmpb	$64, %al
	jle	.L7
	movzbl	-30(%rbp), %eax
	cmpb	$90, %al
	jle	.L6
.L7:
	movzbl	-30(%rbp), %eax
	cmpb	$47, %al
	jle	.L11
	movzbl	-30(%rbp), %eax
	cmpb	$57, %al
	jg	.L11
.L6:
	cmpl	$0, -12(%rbp)
	jne	.L9
	movzbl	-30(%rbp), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	(%rdx,%rdx), %rcx
	leaq	c(%rip), %rdx
	movb	%al, (%rcx,%rdx)
	addl	$1, -12(%rbp)
	jmp	.L11
.L9:
	movzbl	-30(%rbp), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	(%rdx,%rdx), %rcx
	leaq	1+c(%rip), %rdx
	movb	%al, (%rcx,%rdx)
	nop
	addl	$1, -20(%rbp)
.L4:
	movl	-24(%rbp), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L12
	leaq	-28(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -20(%rbp)
	jmp	.L13
.L19:
	leaq	-30(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movzbl	-30(%rbp), %eax
	cmpb	$96, %al
	jle	.L14
	movzbl	-30(%rbp), %eax
	cmpb	$122, %al
	jle	.L15
.L14:
	movzbl	-30(%rbp), %eax
	cmpb	$64, %al
	jle	.L16
	movzbl	-30(%rbp), %eax
	cmpb	$90, %al
	jle	.L15
.L16:
	movzbl	-30(%rbp), %eax
	cmpb	$47, %al
	jle	.L19
	movzbl	-30(%rbp), %eax
	cmpb	$57, %al
	jg	.L19
.L15:
	movzbl	-30(%rbp), %eax
	movb	%al, -29(%rbp)
	nop
	movl	$0, -16(%rbp)
	jmp	.L20
.L23:
	movl	-16(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	c(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	%al, -29(%rbp)
	jne	.L21
	movl	-16(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	1+c(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	movb	%al, -29(%rbp)
	jmp	.L22
.L21:
	addl	$1, -16(%rbp)
.L20:
	movl	-24(%rbp), %eax
	cmpl	%eax, -16(%rbp)
	jl	.L23
.L22:
	movsbl	-29(%rbp), %eax
	movl	%eax, %edi
	call	putchar@PLT
	addl	$1, -20(%rbp)
.L13:
	movl	-28(%rbp), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L19
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L24
.L29:
	nop
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L26
	call	__stack_chk_fail@PLT
.L26:
	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	"%c"
	.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
	leaq	.LC0(%rip), %r15
	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
	leaq	.LC1(%rip), %rbp
	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), %rax
	movq	%rax, 8(%rsp)
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	36(%rsp), %edx
	testl	%edx, %edx
	je	.L2
	jle	.L3
	leaq	c(%rip), %r13
	xorl	%r14d, %r14d
	leaq	31(%rsp), %rbx
	.p2align 4,,10
	.p2align 3
.L4:
	xorl	%r12d, %r12d
	.p2align 4,,10
	.p2align 3
.L8:
	movq	%rbx, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movzbl	31(%rsp), %edx
	movl	%edx, %eax
	andl	$-33, %eax
	subl	$65, %eax
	cmpb	$25, %al
	jbe	.L5
	leal	-48(%rdx), %eax
	cmpb	$9, %al
	ja	.L8
.L5:
	testl	%r12d, %r12d
	jne	.L7
	movb	%dl, 0(%r13)
	movl	$1, %r12d
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L7:
	movb	%dl, 1(%r13)
	addl	$1, %r14d
	addq	$2, %r13
	cmpl	%r14d, 36(%rsp)
	jg	.L4
.L3:
	leaq	32(%rsp), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	xorl	%r13d, %r13d
	call	__isoc99_scanf@PLT
	movl	32(%rsp), %eax
	leaq	31(%rsp), %rbx
	leaq	c(%rip), %r12
	testl	%eax, %eax
	jg	.L15
	jmp	.L18
	.p2align 4,,10
	.p2align 3
.L11:
	leal	-48(%rdi), %eax
	cmpb	$9, %al
	jbe	.L14
.L15:
	movq	%rbp, %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movsbl	31(%rsp), %edi
	movl	%edi, %eax
	andl	$-33, %eax
	subl	$65, %eax
	cmpb	$25, %al
	ja	.L11
.L14:
	movslq	36(%rsp), %rcx
	xorl	%eax, %eax
	testl	%ecx, %ecx
	jg	.L17
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L16:
	addq	$1, %rax
	cmpq	%rax, %rcx
	je	.L13
.L17:
	movslq	%eax, %rdx
	cmpb	%dil, (%r12,%rax,2)
	jne	.L16
	movsbl	1(%r12,%rdx,2), %edi
.L13:
	call	putchar@PLT
	addl	$1, %r13d
	cmpl	%r13d, 32(%rsp)
	jg	.L15
.L18:
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L10
.L2:
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L27
	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
.L27:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2000
c:
	.zero	2000
	.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	"%c"
	.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
	leaq	.LC0(%rip), %r15
	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
	leaq	.LC1(%rip), %rbp
	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), %rax
	movq	%rax, 8(%rsp)
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	36(%rsp), %edx
	testl	%edx, %edx
	je	.L2
	jle	.L3
	leaq	c(%rip), %r13
	xorl	%r14d, %r14d
	leaq	31(%rsp), %rbx
	.p2align 4,,10
	.p2align 3
.L4:
	xorl	%r12d, %r12d
	.p2align 4,,10
	.p2align 3
.L8:
	movq	%rbx, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movzbl	31(%rsp), %edx
	movl	%edx, %eax
	andl	$-33, %eax
	subl	$65, %eax
	cmpb	$25, %al
	jbe	.L5
	leal	-48(%rdx), %eax
	cmpb	$9, %al
	ja	.L8
.L5:
	testl	%r12d, %r12d
	jne	.L7
	movb	%dl, 0(%r13)
	movl	$1, %r12d
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L7:
	movb	%dl, 1(%r13)
	addl	$1, %r14d
	addq	$2, %r13
	cmpl	%r14d, 36(%rsp)
	jg	.L4
.L3:
	leaq	32(%rsp), %rsi
	movq	%r15, %rdi
	xorl	%eax, %eax
	xorl	%r13d, %r13d
	call	__isoc99_scanf@PLT
	movl	32(%rsp), %eax
	leaq	31(%rsp), %rbx
	leaq	c(%rip), %r12
	testl	%eax, %eax
	jg	.L15
	jmp	.L18
	.p2align 4,,10
	.p2align 3
.L11:
	leal	-48(%rdi), %eax
	cmpb	$9, %al
	jbe	.L14
.L15:
	movq	%rbp, %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movsbl	31(%rsp), %edi
	movl	%edi, %eax
	andl	$-33, %eax
	subl	$65, %eax
	cmpb	$25, %al
	ja	.L11
.L14:
	movslq	36(%rsp), %rcx
	xorl	%eax, %eax
	testl	%ecx, %ecx
	jg	.L17
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L16:
	addq	$1, %rax
	cmpq	%rax, %rcx
	je	.L13
.L17:
	movslq	%eax, %rdx
	cmpb	%dil, (%r12,%rax,2)
	jne	.L16
	movsbl	1(%r12,%rdx,2), %edi
.L13:
	call	putchar@PLT
	addl	$1, %r13d
	cmpl	%r13d, 32(%rsp)
	jg	.L15
.L18:
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L10
.L2:
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L27
	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
.L27:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2000
c:
	.zero	2000
	.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>
struct change{
	char c;
	char newC;
};
struct change c[1000];
int main(){
	int n,i,j,k,m,count;
	char str,tc;
	while(1){
		scanf("%d",&m);
		if(!m)break;
		for(i=0;i<m;i++){
			count=0;
			while(1){
				scanf("%c",&str);
				if(('a'<= str && str <='z') || ('A'<= str && str <='Z')||('0'<= str && str <='9')){
					if(count==0){
						c[i].c=str;count++;
					}
					else{
						c[i].newC=str;
						break;
					}
				}
			}
		}
		scanf("%d",&n);
		for(i=0;i<n;i++){
			while(1){
				scanf("%c",&str);
				if(('a'<= str && str <='z') || ('A'<= str && str <='Z')||('0'<= str && str <='9')){
					tc=str;
					break;
				}
			}
			for(j=0;j<m;j++)
				if(c[j].c==tc){tc=c[j].newC;break;}
			printf("%c",tc);
		}
		printf("\n");
	}
	return 0;
}
3
A a
0 5
5 4
10
B
B
C
0
1
4
5
a
b
A
3
A a
0 5
5 4
10
A
B
C
0
1
4
5
a
b
A
0
 3
A a
0 0
5 4
10
B
B
C
0
1
4
5
a
b
A
3
A a
0 5
5 4
10
A
B
C
0
1
4
5
a
b
A
0

BBC5144aba
aBC5144aba
 BBC0144aba
aBC5144aba

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>
struct change{
	char c;
	char newC;
};
struct change c[1000];
int main(){
	int n,i,j,k,m,count;
	char str,tc;
	while(1){
		scanf("%d",&m);
		if(!m)break;
		for(i=0;i<m;i++){
			count=0;
			while(1){
				scanf("%c",&str);
				if(('a'<= str && str <='z') || ('A'<= str && str <='Z')||('0'<= str && str <='9')){
					if(count==0){
						c[i].c=str;count++;
					}
					else{
						c[i].newC=str;
						break;
					}
				}
			}
		}
		scanf("%d",&n);
		for(i=0;i<n;i++){
			while(1){
				scanf("%c",&str);
				if(('a'<= str && str <='z') || ('A'<= str && str <='Z')||('0'<= str && str <='9')){
					tc=str;
					break;
				}
			}
			for(j=0;j<m;j++)
				if(c[j].c==tc){tc=c[j].newC;break;}
			printf("%c",tc);
		}
		printf("\n");
	}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2000
c:
	.zero	2000
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%c"
	.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	$32, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
.L24:
	leaq	-24(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-24(%rbp), %eax
	testl	%eax, %eax
	je	.L29
	movl	$0, -20(%rbp)
	jmp	.L4
.L12:
	movl	$0, -12(%rbp)
.L11:
	leaq	-30(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movzbl	-30(%rbp), %eax
	cmpb	$96, %al
	jle	.L5
	movzbl	-30(%rbp), %eax
	cmpb	$122, %al
	jle	.L6
.L5:
	movzbl	-30(%rbp), %eax
	cmpb	$64, %al
	jle	.L7
	movzbl	-30(%rbp), %eax
	cmpb	$90, %al
	jle	.L6
.L7:
	movzbl	-30(%rbp), %eax
	cmpb	$47, %al
	jle	.L11
	movzbl	-30(%rbp), %eax
	cmpb	$57, %al
	jg	.L11
.L6:
	cmpl	$0, -12(%rbp)
	jne	.L9
	movzbl	-30(%rbp), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	(%rdx,%rdx), %rcx
	leaq	c(%rip), %rdx
	movb	%al, (%rcx,%rdx)
	addl	$1, -12(%rbp)
	jmp	.L11
.L9:
	movzbl	-30(%rbp), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	(%rdx,%rdx), %rcx
	leaq	1+c(%rip), %rdx
	movb	%al, (%rcx,%rdx)
	nop
	addl	$1, -20(%rbp)
.L4:
	movl	-24(%rbp), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L12
	leaq	-28(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -20(%rbp)
	jmp	.L13
.L19:
	leaq	-30(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movzbl	-30(%rbp), %eax
	cmpb	$96, %al
	jle	.L14
	movzbl	-30(%rbp), %eax
	cmpb	$122, %al
	jle	.L15
.L14:
	movzbl	-30(%rbp), %eax
	cmpb	$64, %al
	jle	.L16
	movzbl	-30(%rbp), %eax
	cmpb	$90, %al
	jle	.L15
.L16:
	movzbl	-30(%rbp), %eax
	cmpb	$47, %al
	jle	.L19
	movzbl	-30(%rbp), %eax
	cmpb	$57, %al
	jg	.L19
.L15:
	movzbl	-30(%rbp), %eax
	movb	%al, -29(%rbp)
	nop
	movl	$0, -16(%rbp)
	jmp	.L20
.L23:
	movl	-16(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	c(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	%al, -29(%rbp)
	jne	.L21
	movl	-16(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	1+c(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	movb	%al, -29(%rbp)
	jmp	.L22
.L21:
	addl	$1, -16(%rbp)
.L20:
	movl	-24(%rbp), %eax
	cmpl	%eax, -16(%rbp)
	jl	.L23
.L22:
	movsbl	-29(%rbp), %eax
	movl	%eax, %edi
	call	putchar@PLT
	addl	$1, -20(%rbp)
.L13:
	movl	-28(%rbp), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L19
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L24
.L29:
	nop
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L26
	call	__stack_chk_fail@PLT
.L26:
	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	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 2000
c:
	.zero	2000
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%c"
	.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	$32, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
.L24:
	leaq	-24(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-24(%rbp), %eax
	testl	%eax, %eax
	je	.L29
	movl	$0, -20(%rbp)
	jmp	.L4
.L12:
	movl	$0, -12(%rbp)
.L11:
	leaq	-30(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movzbl	-30(%rbp), %eax
	cmpb	$96, %al
	jle	.L5
	movzbl	-30(%rbp), %eax
	cmpb	$122, %al
	jle	.L6
.L5:
	movzbl	-30(%rbp), %eax
	cmpb	$64, %al
	jle	.L7
	movzbl	-30(%rbp), %eax
	cmpb	$90, %al
	jle	.L6
.L7:
	movzbl	-30(%rbp), %eax
	cmpb	$47, %al
	jle	.L11
	movzbl	-30(%rbp), %eax
	cmpb	$57, %al
	jg	.L11
.L6:
	cmpl	$0, -12(%rbp)
	jne	.L9
	movzbl	-30(%rbp), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	(%rdx,%rdx), %rcx
	leaq	c(%rip), %rdx
	movb	%al, (%rcx,%rdx)
	addl	$1, -12(%rbp)
	jmp	.L11
.L9:
	movzbl	-30(%rbp), %eax
	movl	-20(%rbp), %edx
	movslq	%edx, %rdx
	leaq	(%rdx,%rdx), %rcx
	leaq	1+c(%rip), %rdx
	movb	%al, (%rcx,%rdx)
	nop
	addl	$1, -20(%rbp)
.L4:
	movl	-24(%rbp), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L12
	leaq	-28(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -20(%rbp)
	jmp	.L13
.L19:
	leaq	-30(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movzbl	-30(%rbp), %eax
	cmpb	$96, %al
	jle	.L14
	movzbl	-30(%rbp), %eax
	cmpb	$122, %al
	jle	.L15
.L14:
	movzbl	-30(%rbp), %eax
	cmpb	$64, %al
	jle	.L16
	movzbl	-30(%rbp), %eax
	cmpb	$90, %al
	jle	.L15
.L16:
	movzbl	-30(%rbp), %eax
	cmpb	$47, %al
	jle	.L19
	movzbl	-30(%rbp), %eax
	cmpb	$57, %al
	jg	.L19
.L15:
	movzbl	-30(%rbp), %eax
	movb	%al, -29(%rbp)
	nop
	movl	$0, -16(%rbp)
	jmp	.L20
.L23:
	movl	-16(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	c(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	%al, -29(%rbp)
	jne	.L21
	movl	-16(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	1+c(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	movb	%al, -29(%rbp)
	jmp	.L22
.L21:
	addl	$1, -16(%rbp)
.L20:
	movl	-24(%rbp), %eax
	cmpl	%eax, -16(%rbp)
	jl	.L23
.L22:
	movsbl	-29(%rbp), %eax
	movl	%eax, %edi
	call	putchar@PLT
	addl	$1, -20(%rbp)
.L13:
	movl	-28(%rbp), %eax
	cmpl	%eax, -20(%rbp)
	jl	.L19
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L24
.L29:
	nop
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L26
	call	__stack_chk_fail@PLT
.L26:
	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:
