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>
#include<string.h>
int main(void)
{
    int n,i,j,k,ii,cnt,len,flg,f2,lenn;
    char nama[26];
    char ban[101];
     
    cnt=0;
    scanf("%d",&n);
    scanf("%s",nama);
    lenn=strlen(nama);
    for(i=0;i<n;i++) {
        scanf("%s",ban);
        len=strlen(ban);
        flg=0;
        for(j=0;j<len;j++)   {
			for(k=1;k+j<len;k++) {
				f2=1;
				for(ii=0;ii<lenn;ii++)   {
					if(j+k*ii>=len)    {
						f2=0;
						break;
					}
					if(nama[ii]!=ban[j+k*ii]) {
						f2=0;
						break;
					}
				}
				if(f2==1)   {
					flg=1;
					k=len; j=len;
				}
			}
        }
        if(flg==1)  {
            cnt++;
        }
    }
    printf("%d\n",cnt);
    return 0;
}
```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB35:
	.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	$184, %rsp
	.cfi_def_cfa_offset 240
	movq	%fs:40, %rax
	movq	%rax, 168(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	leaq	32(%rsp), %r12
	call	__isoc99_scanf@PLT
	movq	%r12, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%r12, %rdi
	call	strlen@PLT
	movl	28(%rsp), %edx
	testl	%edx, %edx
	jle	.L16
	movq	%rax, %rbp
	leal	-1(%rax), %eax
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	movl	%eax, 12(%rsp)
	leaq	64(%rsp), %rbx
.L14:
	movq	%rbx, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%rbx, %rdi
	call	strlen@PLT
	movl	12(%rsp), %r9d
	xorl	%r10d, %r10d
	xorl	%edi, %edi
	movl	%eax, %edx
	leaq	(%r9,%r12), %r8
	testq	%rax, %rax
	je	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	leal	1(%rdi), %eax
	cmpl	%eax, %edx
	jle	.L12
	movl	$1, %esi
	.p2align 4,,10
	.p2align 3
.L13:
	testq	%rbp, %rbp
	je	.L19
	cmpl	%edi, %edx
	jle	.L5
	cmpl	$1, %esi
	jne	.L29
	movslq	%edi, %rax
	movq	%r12, %r11
	leaq	(%r9,%rax), %rcx
	subq	%rax, %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L30:
	cmpq	%rcx, %rax
	je	.L18
	addq	$1, %rax
	cmpl	%eax, %edx
	jle	.L5
.L7:
	movzbl	(%r11,%rax), %r15d
	cmpb	%r15b, (%rbx,%rax)
	je	.L30
.L5:
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
.L32:
	addl	$1, %edi
	cmpl	%edx, %edi
	jl	.L3
.L12:
	addl	%r10d, %r13d
.L4:
	addl	$1, %r14d
	cmpl	%r14d, 28(%rsp)
	jg	.L14
.L2:
	xorl	%eax, %eax
	movl	%r13d, %edx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	168(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L31
	addq	$184, %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
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
	.p2align 4,,10
	.p2align 3
.L29:
	movslq	%esi, %r11
	movslq	%edi, %rcx
	movq	%r12, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L33:
	cmpq	%r8, %rax
	je	.L19
	addq	%r11, %rcx
	addq	$1, %rax
	cmpl	%ecx, %edx
	jle	.L5
.L6:
	movzbl	(%rbx,%rcx), %r15d
	cmpb	%r15b, (%rax)
	je	.L33
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L19:
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
.L16:
	xorl	%r13d, %r13d
	jmp	.L2
.L31:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.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"
.LC1:
	.string	"%s"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB35:
	.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	$184, %rsp
	.cfi_def_cfa_offset 240
	movq	%fs:40, %rax
	movq	%rax, 168(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	leaq	32(%rsp), %r12
	call	__isoc99_scanf@PLT
	movq	%r12, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%r12, %rdi
	call	strlen@PLT
	movl	28(%rsp), %edx
	testl	%edx, %edx
	jle	.L16
	movq	%rax, %rbp
	leal	-1(%rax), %eax
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	movl	%eax, 12(%rsp)
	leaq	64(%rsp), %rbx
.L14:
	movq	%rbx, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%rbx, %rdi
	call	strlen@PLT
	movl	12(%rsp), %r9d
	xorl	%r10d, %r10d
	xorl	%edi, %edi
	movl	%eax, %edx
	leaq	(%r9,%r12), %r8
	testq	%rax, %rax
	je	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	leal	1(%rdi), %eax
	cmpl	%eax, %edx
	jle	.L12
	movl	$1, %esi
	.p2align 4,,10
	.p2align 3
.L13:
	testq	%rbp, %rbp
	je	.L19
	cmpl	%edi, %edx
	jle	.L5
	cmpl	$1, %esi
	jne	.L29
	movslq	%edi, %rax
	movq	%r12, %r11
	leaq	(%r9,%rax), %rcx
	subq	%rax, %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L30:
	cmpq	%rcx, %rax
	je	.L18
	addq	$1, %rax
	cmpl	%eax, %edx
	jle	.L5
.L7:
	movzbl	(%r11,%rax), %r15d
	cmpb	%r15b, (%rbx,%rax)
	je	.L30
.L5:
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
.L32:
	addl	$1, %edi
	cmpl	%edx, %edi
	jl	.L3
.L12:
	addl	%r10d, %r13d
.L4:
	addl	$1, %r14d
	cmpl	%r14d, 28(%rsp)
	jg	.L14
.L2:
	xorl	%eax, %eax
	movl	%r13d, %edx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	168(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L31
	addq	$184, %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
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
	.p2align 4,,10
	.p2align 3
.L29:
	movslq	%esi, %r11
	movslq	%edi, %rcx
	movq	%r12, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L33:
	cmpq	%r8, %rax
	je	.L19
	addq	%r11, %rcx
	addq	$1, %rax
	cmpl	%ecx, %edx
	jle	.L5
.L6:
	movzbl	(%rbx,%rcx), %r15d
	cmpb	%r15b, (%rax)
	je	.L33
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L19:
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
.L16:
	xorl	%r13d, %r13d
	jmp	.L2
.L31:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.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"
.LC1:
	.string	"%s"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB35:
	.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	$184, %rsp
	.cfi_def_cfa_offset 240
	movq	%fs:40, %rax
	movq	%rax, 168(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	leaq	32(%rsp), %r12
	call	__isoc99_scanf@PLT
	movq	%r12, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%r12, %rdi
	call	strlen@PLT
	movl	28(%rsp), %edx
	testl	%edx, %edx
	jle	.L16
	movq	%rax, %rbp
	leal	-1(%rax), %eax
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	movl	%eax, 12(%rsp)
	leaq	64(%rsp), %rbx
.L14:
	movq	%rbx, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%rbx, %rdi
	call	strlen@PLT
	movl	12(%rsp), %r9d
	xorl	%r10d, %r10d
	xorl	%edi, %edi
	movl	%eax, %edx
	leaq	(%r9,%r12), %r8
	testq	%rax, %rax
	je	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	leal	1(%rdi), %eax
	cmpl	%eax, %edx
	jle	.L12
	movl	$1, %esi
	.p2align 4,,10
	.p2align 3
.L13:
	testq	%rbp, %rbp
	je	.L19
	cmpl	%edi, %edx
	jle	.L5
	cmpl	$1, %esi
	jne	.L29
	movslq	%edi, %rax
	movq	%r12, %r11
	leaq	(%r9,%rax), %rcx
	subq	%rax, %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L30:
	cmpq	%rcx, %rax
	je	.L18
	addq	$1, %rax
	cmpl	%eax, %edx
	jle	.L5
.L7:
	movzbl	(%r11,%rax), %r15d
	cmpb	%r15b, (%rbx,%rax)
	je	.L30
.L5:
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
.L32:
	addl	$1, %edi
	cmpl	%edx, %edi
	jl	.L3
.L12:
	addl	%r10d, %r13d
.L4:
	addl	$1, %r14d
	cmpl	%r14d, 28(%rsp)
	jg	.L14
.L2:
	xorl	%eax, %eax
	movl	%r13d, %edx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	168(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L31
	addq	$184, %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
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
	.p2align 4,,10
	.p2align 3
.L29:
	movslq	%esi, %r11
	movslq	%edi, %rcx
	movq	%r12, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L33:
	cmpq	%r8, %rax
	je	.L19
	addq	%r11, %rcx
	addq	$1, %rax
	cmpl	%ecx, %edx
	jle	.L5
.L6:
	movzbl	(%rbx,%rcx), %r15d
	cmpb	%r15b, (%rax)
	je	.L33
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L19:
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
.L16:
	xorl	%r13d, %r13d
	jmp	.L2
.L31:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.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>
#include<string.h>
int main(void)
{
    int n,i,j,k,ii,cnt,len,flg,f2,lenn;
    char nama[26];
    char ban[101];
     
    cnt=0;
    scanf("%d",&n);
    scanf("%s",nama);
    lenn=strlen(nama);
    for(i=0;i<n;i++) {
        scanf("%s",ban);
        len=strlen(ban);
        flg=0;
        for(j=0;j<len;j++)   {
			for(k=1;k+j<len;k++) {
				f2=1;
				for(ii=0;ii<lenn;ii++)   {
					if(j+k*ii>=len)    {
						f2=0;
						break;
					}
					if(nama[ii]!=ban[j+k*ii]) {
						f2=0;
						break;
					}
				}
				if(f2==1)   {
					flg=1;
					k=len; j=len;
				}
			}
        }
        if(flg==1)  {
            cnt++;
        }
    }
    printf("%d\n",cnt);
    return 0;
}
```
Given the following C code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>
#include<string.h>
int main(void)
{
    int n,i,j,k,ii,cnt,len,flg,f2,lenn;
    char nama[26];
    char ban[101];
     
    cnt=0;
    scanf("%d",&n);
    scanf("%s",nama);
    lenn=strlen(nama);
    for(i=0;i<n;i++) {
        scanf("%s",ban);
        len=strlen(ban);
        flg=0;
        for(j=0;j<len;j++)   {
			for(k=1;k+j<len;k++) {
				f2=1;
				for(ii=0;ii<lenn;ii++)   {
					if(j+k*ii>=len)    {
						f2=0;
						break;
					}
					if(nama[ii]!=ban[j+k*ii]) {
						f2=0;
						break;
					}
				}
				if(f2==1)   {
					flg=1;
					k=len; j=len;
				}
			}
        }
        if(flg==1)  {
            cnt++;
        }
    }
    printf("%d\n",cnt);
    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:

4
bar
abracadabra
bear
bar
bbraxbara
 4
rab
abracadabra
bear
bar
bbraxbara
 4
rab
abracadabra
bear
bar
arabxarbb
 4
qab
abracadabra
bear
bar
arabxarbb
 4
qab
abracadabra
bear
bra
arabxarbb
 4
qab
abrbcadaara
bear
bra
arabxarbb
 4
qab
abrbcadaara
bear
bra
arbbxarbb
 4
qab
abrbcadaara
raeb
bra
arbbxarbb
 4
qab
abrbcadaara
rafb
bra
arbbxarbb
 4
baq
abrbcadaara
rafb
bra
arbbxarbb

3
 1
 2
 0
 0
 0
 0
 0
 0
 0

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>
#include<string.h>
int main(void)
{
    int n,i,j,k,ii,cnt,len,flg,f2,lenn;
    char nama[26];
    char ban[101];
     
    cnt=0;
    scanf("%d",&n);
    scanf("%s",nama);
    lenn=strlen(nama);
    for(i=0;i<n;i++) {
        scanf("%s",ban);
        len=strlen(ban);
        flg=0;
        for(j=0;j<len;j++)   {
			for(k=1;k+j<len;k++) {
				f2=1;
				for(ii=0;ii<lenn;ii++)   {
					if(j+k*ii>=len)    {
						f2=0;
						break;
					}
					if(nama[ii]!=ban[j+k*ii]) {
						f2=0;
						break;
					}
				}
				if(f2==1)   {
					flg=1;
					k=len; j=len;
				}
			}
        }
        if(flg==1)  {
            cnt++;
        }
    }
    printf("%d\n",cnt);
    return 0;
}
```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB35:
	.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	$184, %rsp
	.cfi_def_cfa_offset 240
	movq	%fs:40, %rax
	movq	%rax, 168(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	leaq	32(%rsp), %r12
	call	__isoc99_scanf@PLT
	movq	%r12, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%r12, %rdi
	call	strlen@PLT
	movl	28(%rsp), %edx
	testl	%edx, %edx
	jle	.L16
	movq	%rax, %rbp
	leal	-1(%rax), %eax
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	movl	%eax, 12(%rsp)
	leaq	64(%rsp), %rbx
.L14:
	movq	%rbx, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%rbx, %rdi
	call	strlen@PLT
	movl	12(%rsp), %r9d
	xorl	%r10d, %r10d
	xorl	%edi, %edi
	movl	%eax, %edx
	leaq	(%r9,%r12), %r8
	testq	%rax, %rax
	je	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	leal	1(%rdi), %eax
	cmpl	%eax, %edx
	jle	.L12
	movl	$1, %esi
	.p2align 4,,10
	.p2align 3
.L13:
	testq	%rbp, %rbp
	je	.L19
	cmpl	%edi, %edx
	jle	.L5
	cmpl	$1, %esi
	jne	.L29
	movslq	%edi, %rax
	movq	%r12, %r11
	leaq	(%r9,%rax), %rcx
	subq	%rax, %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L30:
	cmpq	%rcx, %rax
	je	.L18
	addq	$1, %rax
	cmpl	%eax, %edx
	jle	.L5
.L7:
	movzbl	(%r11,%rax), %r15d
	cmpb	%r15b, (%rbx,%rax)
	je	.L30
.L5:
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
.L32:
	addl	$1, %edi
	cmpl	%edx, %edi
	jl	.L3
.L12:
	addl	%r10d, %r13d
.L4:
	addl	$1, %r14d
	cmpl	%r14d, 28(%rsp)
	jg	.L14
.L2:
	xorl	%eax, %eax
	movl	%r13d, %edx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	168(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L31
	addq	$184, %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
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
	.p2align 4,,10
	.p2align 3
.L29:
	movslq	%esi, %r11
	movslq	%edi, %rcx
	movq	%r12, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L33:
	cmpq	%r8, %rax
	je	.L19
	addq	%r11, %rcx
	addq	$1, %rax
	cmpl	%ecx, %edx
	jle	.L5
.L6:
	movzbl	(%rbx,%rcx), %r15d
	cmpb	%r15b, (%rax)
	je	.L33
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L19:
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
.L16:
	xorl	%r13d, %r13d
	jmp	.L2
.L31:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.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"
.LC1:
	.string	"%s"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB35:
	.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	$184, %rsp
	.cfi_def_cfa_offset 240
	movq	%fs:40, %rax
	movq	%rax, 168(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	leaq	32(%rsp), %r12
	call	__isoc99_scanf@PLT
	movq	%r12, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%r12, %rdi
	call	strlen@PLT
	movl	28(%rsp), %edx
	testl	%edx, %edx
	jle	.L16
	movq	%rax, %rbp
	leal	-1(%rax), %eax
	xorl	%r13d, %r13d
	xorl	%r14d, %r14d
	movl	%eax, 12(%rsp)
	leaq	64(%rsp), %rbx
.L14:
	movq	%rbx, %rsi
	leaq	.LC1(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	%rbx, %rdi
	call	strlen@PLT
	movl	12(%rsp), %r9d
	xorl	%r10d, %r10d
	xorl	%edi, %edi
	movl	%eax, %edx
	leaq	(%r9,%r12), %r8
	testq	%rax, %rax
	je	.L4
	.p2align 4,,10
	.p2align 3
.L3:
	leal	1(%rdi), %eax
	cmpl	%eax, %edx
	jle	.L12
	movl	$1, %esi
	.p2align 4,,10
	.p2align 3
.L13:
	testq	%rbp, %rbp
	je	.L19
	cmpl	%edi, %edx
	jle	.L5
	cmpl	$1, %esi
	jne	.L29
	movslq	%edi, %rax
	movq	%r12, %r11
	leaq	(%r9,%rax), %rcx
	subq	%rax, %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L30:
	cmpq	%rcx, %rax
	je	.L18
	addq	$1, %rax
	cmpl	%eax, %edx
	jle	.L5
.L7:
	movzbl	(%r11,%rax), %r15d
	cmpb	%r15b, (%rbx,%rax)
	je	.L30
.L5:
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
.L32:
	addl	$1, %edi
	cmpl	%edx, %edi
	jl	.L3
.L12:
	addl	%r10d, %r13d
.L4:
	addl	$1, %r14d
	cmpl	%r14d, 28(%rsp)
	jg	.L14
.L2:
	xorl	%eax, %eax
	movl	%r13d, %edx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	168(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L31
	addq	$184, %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
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
	.p2align 4,,10
	.p2align 3
.L29:
	movslq	%esi, %r11
	movslq	%edi, %rcx
	movq	%r12, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L33:
	cmpq	%r8, %rax
	je	.L19
	addq	%r11, %rcx
	addq	$1, %rax
	cmpl	%ecx, %edx
	jle	.L5
.L6:
	movzbl	(%rbx,%rcx), %r15d
	cmpb	%r15b, (%rax)
	je	.L33
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L19:
	movl	%edx, %esi
	movl	%edx, %edi
	movl	$1, %r10d
	addl	$1, %esi
	leal	(%rdi,%rsi), %eax
	cmpl	%edx, %eax
	jl	.L13
	jmp	.L32
.L16:
	xorl	%r13d, %r13d
	jmp	.L2
.L31:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.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:
```