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>
int main(){
  int n,i,j,d[200][3];
  int s[200]={0};
  scanf("%d",&n);
  for(i=0;i<n*3;i++)scanf("%d",&d[i/3][i%3]);
  for(i=0;i<3;i++){
    char c[101]={0};
    for(j=0;j<n;j++)c[d[j][i]]++;
    for(j=0;j<n;j++){
      if(c[d[j][i]]==1)s[j]+=d[j][i];
    }
  }
  for(i=0;i<n;i++)printf("%d\n",s[i]);
  return 0;
}```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.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
	movl	$100, %ecx
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC0(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$3328, %rsp
	.cfi_def_cfa_offset 3376
	movq	%fs:40, %rax
	movq	%rax, 3320(%rsp)
	xorl	%eax, %eax
	leaq	16(%rsp), %rbx
	leaq	12(%rsp), %rsi
	movq	%rbx, %rdi
	leaq	816(%rsp), %rbp
	rep stosq
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	testl	%r8d, %r8d
	jle	.L2
	xorl	%r14d, %r14d
	leaq	816(%rsp), %rbp
	movl	$2863311531, %r13d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r14d, %eax
	movq	%r12, %rdi
	imulq	%r13, %rax
	shrq	$33, %rax
	leal	(%rax,%rax,2), %ecx
	movslq	%eax, %rdx
	movl	%r14d, %eax
	addl	$1, %r14d
	subl	%ecx, %eax
	leaq	(%rdx,%rdx,2), %rdx
	cltq
	addq	%rdx, %rax
	leaq	0(%rbp,%rax,4), %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	leal	(%r8,%r8,2), %eax
	cmpl	%r14d, %eax
	jg	.L3
.L2:
	leal	-1(%r8), %eax
	leaq	828(%rsp), %r10
	leaq	(%rax,%rax,2), %rdx
	leaq	20(%rsp,%rax,4), %r9
	leaq	(%r10,%rdx,4), %rdi
.L5:
	pxor	%xmm0, %xmm0
	movb	$0, 3316(%rsp)
	movq	%rbp, %rax
	movl	$0, 3312(%rsp)
	movaps	%xmm0, 3216(%rsp)
	movaps	%xmm0, 3232(%rsp)
	movaps	%xmm0, 3248(%rsp)
	movaps	%xmm0, 3264(%rsp)
	movaps	%xmm0, 3280(%rsp)
	movaps	%xmm0, 3296(%rsp)
	testl	%r8d, %r8d
	jle	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	movslq	(%rax), %rdx
	addq	$12, %rax
	addb	$1, 3216(%rsp,%rdx)
	cmpq	%rdi, %rax
	jne	.L4
	movq	%rbx, %rax
	movq	%rbp, %rdx
	.p2align 4,,10
	.p2align 3
.L8:
	movslq	(%rdx), %rsi
	cmpb	$1, 3216(%rsp,%rsi)
	jne	.L7
	addl	%esi, (%rax)
.L7:
	addq	$4, %rax
	addq	$12, %rdx
	cmpq	%rax, %r9
	jne	.L8
.L9:
	addq	$4, %rbp
	addq	$4, %rdi
	cmpq	%rbp, %r10
	jne	.L5
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r12
	testl	%r8d, %r8d
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 12(%rsp)
	jg	.L10
.L11:
	movq	3320(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L28
	addq	$3328, %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
.L28:
	.cfi_restore_state
	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"
.LC1:
	.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
	movl	$100, %ecx
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC0(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$3328, %rsp
	.cfi_def_cfa_offset 3376
	movq	%fs:40, %rax
	movq	%rax, 3320(%rsp)
	xorl	%eax, %eax
	leaq	16(%rsp), %rbx
	leaq	12(%rsp), %rsi
	movq	%rbx, %rdi
	leaq	816(%rsp), %rbp
	rep stosq
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	testl	%r8d, %r8d
	jle	.L2
	xorl	%r14d, %r14d
	leaq	816(%rsp), %rbp
	movl	$2863311531, %r13d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r14d, %eax
	movq	%r12, %rdi
	imulq	%r13, %rax
	shrq	$33, %rax
	leal	(%rax,%rax,2), %ecx
	movslq	%eax, %rdx
	movl	%r14d, %eax
	addl	$1, %r14d
	subl	%ecx, %eax
	leaq	(%rdx,%rdx,2), %rdx
	cltq
	addq	%rdx, %rax
	leaq	0(%rbp,%rax,4), %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	leal	(%r8,%r8,2), %eax
	cmpl	%r14d, %eax
	jg	.L3
.L2:
	leal	-1(%r8), %eax
	leaq	828(%rsp), %r10
	leaq	(%rax,%rax,2), %rdx
	leaq	20(%rsp,%rax,4), %r9
	leaq	(%r10,%rdx,4), %rdi
.L5:
	pxor	%xmm0, %xmm0
	movb	$0, 3316(%rsp)
	movq	%rbp, %rax
	movl	$0, 3312(%rsp)
	movaps	%xmm0, 3216(%rsp)
	movaps	%xmm0, 3232(%rsp)
	movaps	%xmm0, 3248(%rsp)
	movaps	%xmm0, 3264(%rsp)
	movaps	%xmm0, 3280(%rsp)
	movaps	%xmm0, 3296(%rsp)
	testl	%r8d, %r8d
	jle	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	movslq	(%rax), %rdx
	addq	$12, %rax
	addb	$1, 3216(%rsp,%rdx)
	cmpq	%rdi, %rax
	jne	.L4
	movq	%rbx, %rax
	movq	%rbp, %rdx
	.p2align 4,,10
	.p2align 3
.L8:
	movslq	(%rdx), %rsi
	cmpb	$1, 3216(%rsp,%rsi)
	jne	.L7
	addl	%esi, (%rax)
.L7:
	addq	$4, %rax
	addq	$12, %rdx
	cmpq	%rax, %r9
	jne	.L8
.L9:
	addq	$4, %rbp
	addq	$4, %rdi
	cmpq	%rbp, %r10
	jne	.L5
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r12
	testl	%r8d, %r8d
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 12(%rsp)
	jg	.L10
.L11:
	movq	3320(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L28
	addq	$3328, %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
.L28:
	.cfi_restore_state
	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"
.LC1:
	.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
	movl	$100, %ecx
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC0(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$3328, %rsp
	.cfi_def_cfa_offset 3376
	movq	%fs:40, %rax
	movq	%rax, 3320(%rsp)
	xorl	%eax, %eax
	leaq	16(%rsp), %rbx
	leaq	12(%rsp), %rsi
	movq	%rbx, %rdi
	leaq	816(%rsp), %rbp
	rep stosq
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	testl	%r8d, %r8d
	jle	.L2
	xorl	%r14d, %r14d
	leaq	816(%rsp), %rbp
	movl	$2863311531, %r13d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r14d, %eax
	movq	%r12, %rdi
	imulq	%r13, %rax
	shrq	$33, %rax
	leal	(%rax,%rax,2), %ecx
	movslq	%eax, %rdx
	movl	%r14d, %eax
	addl	$1, %r14d
	subl	%ecx, %eax
	leaq	(%rdx,%rdx,2), %rdx
	cltq
	addq	%rdx, %rax
	leaq	0(%rbp,%rax,4), %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	leal	(%r8,%r8,2), %eax
	cmpl	%r14d, %eax
	jg	.L3
.L2:
	leal	-1(%r8), %eax
	leaq	828(%rsp), %r10
	leaq	(%rax,%rax,2), %rdx
	leaq	20(%rsp,%rax,4), %r9
	leaq	(%r10,%rdx,4), %rdi
.L5:
	pxor	%xmm0, %xmm0
	movb	$0, 3316(%rsp)
	movq	%rbp, %rax
	movl	$0, 3312(%rsp)
	movaps	%xmm0, 3216(%rsp)
	movaps	%xmm0, 3232(%rsp)
	movaps	%xmm0, 3248(%rsp)
	movaps	%xmm0, 3264(%rsp)
	movaps	%xmm0, 3280(%rsp)
	movaps	%xmm0, 3296(%rsp)
	testl	%r8d, %r8d
	jle	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	movslq	(%rax), %rdx
	addq	$12, %rax
	addb	$1, 3216(%rsp,%rdx)
	cmpq	%rdi, %rax
	jne	.L4
	movq	%rbx, %rax
	movq	%rbp, %rdx
	.p2align 4,,10
	.p2align 3
.L8:
	movslq	(%rdx), %rsi
	cmpb	$1, 3216(%rsp,%rsi)
	jne	.L7
	addl	%esi, (%rax)
.L7:
	addq	$4, %rax
	addq	$12, %rdx
	cmpq	%rax, %r9
	jne	.L8
.L9:
	addq	$4, %rbp
	addq	$4, %rdi
	cmpq	%rbp, %r10
	jne	.L5
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r12
	testl	%r8d, %r8d
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 12(%rsp)
	jg	.L10
.L11:
	movq	3320(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L28
	addq	$3328, %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
.L28:
	.cfi_restore_state
	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>
int main(){
  int n,i,j,d[200][3];
  int s[200]={0};
  scanf("%d",&n);
  for(i=0;i<n*3;i++)scanf("%d",&d[i/3][i%3]);
  for(i=0;i<3;i++){
    char c[101]={0};
    for(j=0;j<n;j++)c[d[j][i]]++;
    for(j=0;j<n;j++){
      if(c[d[j][i]]==1)s[j]+=d[j][i];
    }
  }
  for(i=0;i<n;i++)printf("%d\n",s[i]);
  return 0;
}```
Given the following C code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>
int main(){
  int n,i,j,d[200][3];
  int s[200]={0};
  scanf("%d",&n);
  for(i=0;i<n*3;i++)scanf("%d",&d[i/3][i%3]);
  for(i=0;i<3;i++){
    char c[101]={0};
    for(j=0;j<n;j++)c[d[j][i]]++;
    for(j=0;j<n;j++){
      if(c[d[j][i]]==1)s[j]+=d[j][i];
    }
  }
  for(i=0;i<n;i++)printf("%d\n",s[i]);
  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:

5
100 99 98
100 97 68
63 89 63
99 99 99
89 97 98
 5
100 99 98
100 97 68
63 89 63
68 99 99
89 97 98
 5
100 99 98
100 97 92
63 53 63
99 99 99
89 97 98
 5
100 99 98
100 97 68
63 89 63
68 99 79
89 97 98
 5
100 99 98
100 97 92
63 32 63
99 99 99
89 97 98
 5
100 99 98
100 97 68
63 89 25
68 99 79
89 97 98
 5
100 99 98
000 97 92
63 32 63
99 99 99
89 97 98
 5
100 1 98
100 97 68
63 89 25
68 99 79
89 97 98
 5
100 1 98
100 97 68
44 89 25
68 99 79
89 97 98
 5
100 1 98
100 97 68
16 89 25
68 99 79
89 97 98

0
68
215
198
89
 0
68
215
167
89
 0
92
179
198
89
 0
68
215
147
89
 0
92
158
198
89
 0
68
177
147
89
 100
92
158
198
89
 1
68
177
246
89
 1
68
158
246
89
 1
68
130
246
89

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>
int main(){
  int n,i,j,d[200][3];
  int s[200]={0};
  scanf("%d",&n);
  for(i=0;i<n*3;i++)scanf("%d",&d[i/3][i%3]);
  for(i=0;i<3;i++){
    char c[101]={0};
    for(j=0;j<n;j++)c[d[j][i]]++;
    for(j=0;j<n;j++){
      if(c[d[j][i]]==1)s[j]+=d[j][i];
    }
  }
  for(i=0;i<n;i++)printf("%d\n",s[i]);
  return 0;
}```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.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
	movl	$100, %ecx
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC0(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$3328, %rsp
	.cfi_def_cfa_offset 3376
	movq	%fs:40, %rax
	movq	%rax, 3320(%rsp)
	xorl	%eax, %eax
	leaq	16(%rsp), %rbx
	leaq	12(%rsp), %rsi
	movq	%rbx, %rdi
	leaq	816(%rsp), %rbp
	rep stosq
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	testl	%r8d, %r8d
	jle	.L2
	xorl	%r14d, %r14d
	leaq	816(%rsp), %rbp
	movl	$2863311531, %r13d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r14d, %eax
	movq	%r12, %rdi
	imulq	%r13, %rax
	shrq	$33, %rax
	leal	(%rax,%rax,2), %ecx
	movslq	%eax, %rdx
	movl	%r14d, %eax
	addl	$1, %r14d
	subl	%ecx, %eax
	leaq	(%rdx,%rdx,2), %rdx
	cltq
	addq	%rdx, %rax
	leaq	0(%rbp,%rax,4), %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	leal	(%r8,%r8,2), %eax
	cmpl	%r14d, %eax
	jg	.L3
.L2:
	leal	-1(%r8), %eax
	leaq	828(%rsp), %r10
	leaq	(%rax,%rax,2), %rdx
	leaq	20(%rsp,%rax,4), %r9
	leaq	(%r10,%rdx,4), %rdi
.L5:
	pxor	%xmm0, %xmm0
	movb	$0, 3316(%rsp)
	movq	%rbp, %rax
	movl	$0, 3312(%rsp)
	movaps	%xmm0, 3216(%rsp)
	movaps	%xmm0, 3232(%rsp)
	movaps	%xmm0, 3248(%rsp)
	movaps	%xmm0, 3264(%rsp)
	movaps	%xmm0, 3280(%rsp)
	movaps	%xmm0, 3296(%rsp)
	testl	%r8d, %r8d
	jle	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	movslq	(%rax), %rdx
	addq	$12, %rax
	addb	$1, 3216(%rsp,%rdx)
	cmpq	%rdi, %rax
	jne	.L4
	movq	%rbx, %rax
	movq	%rbp, %rdx
	.p2align 4,,10
	.p2align 3
.L8:
	movslq	(%rdx), %rsi
	cmpb	$1, 3216(%rsp,%rsi)
	jne	.L7
	addl	%esi, (%rax)
.L7:
	addq	$4, %rax
	addq	$12, %rdx
	cmpq	%rax, %r9
	jne	.L8
.L9:
	addq	$4, %rbp
	addq	$4, %rdi
	cmpq	%rbp, %r10
	jne	.L5
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r12
	testl	%r8d, %r8d
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 12(%rsp)
	jg	.L10
.L11:
	movq	3320(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L28
	addq	$3328, %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
.L28:
	.cfi_restore_state
	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"
.LC1:
	.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
	movl	$100, %ecx
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC0(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$3328, %rsp
	.cfi_def_cfa_offset 3376
	movq	%fs:40, %rax
	movq	%rax, 3320(%rsp)
	xorl	%eax, %eax
	leaq	16(%rsp), %rbx
	leaq	12(%rsp), %rsi
	movq	%rbx, %rdi
	leaq	816(%rsp), %rbp
	rep stosq
	movq	%r12, %rdi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	testl	%r8d, %r8d
	jle	.L2
	xorl	%r14d, %r14d
	leaq	816(%rsp), %rbp
	movl	$2863311531, %r13d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r14d, %eax
	movq	%r12, %rdi
	imulq	%r13, %rax
	shrq	$33, %rax
	leal	(%rax,%rax,2), %ecx
	movslq	%eax, %rdx
	movl	%r14d, %eax
	addl	$1, %r14d
	subl	%ecx, %eax
	leaq	(%rdx,%rdx,2), %rdx
	cltq
	addq	%rdx, %rax
	leaq	0(%rbp,%rax,4), %rsi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %r8d
	leal	(%r8,%r8,2), %eax
	cmpl	%r14d, %eax
	jg	.L3
.L2:
	leal	-1(%r8), %eax
	leaq	828(%rsp), %r10
	leaq	(%rax,%rax,2), %rdx
	leaq	20(%rsp,%rax,4), %r9
	leaq	(%r10,%rdx,4), %rdi
.L5:
	pxor	%xmm0, %xmm0
	movb	$0, 3316(%rsp)
	movq	%rbp, %rax
	movl	$0, 3312(%rsp)
	movaps	%xmm0, 3216(%rsp)
	movaps	%xmm0, 3232(%rsp)
	movaps	%xmm0, 3248(%rsp)
	movaps	%xmm0, 3264(%rsp)
	movaps	%xmm0, 3280(%rsp)
	movaps	%xmm0, 3296(%rsp)
	testl	%r8d, %r8d
	jle	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	movslq	(%rax), %rdx
	addq	$12, %rax
	addb	$1, 3216(%rsp,%rdx)
	cmpq	%rdi, %rax
	jne	.L4
	movq	%rbx, %rax
	movq	%rbp, %rdx
	.p2align 4,,10
	.p2align 3
.L8:
	movslq	(%rdx), %rsi
	cmpb	$1, 3216(%rsp,%rsi)
	jne	.L7
	addl	%esi, (%rax)
.L7:
	addq	$4, %rax
	addq	$12, %rdx
	cmpq	%rax, %r9
	jne	.L8
.L9:
	addq	$4, %rbp
	addq	$4, %rdi
	cmpq	%rbp, %r10
	jne	.L5
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r12
	testl	%r8d, %r8d
	jle	.L11
	.p2align 4,,10
	.p2align 3
.L10:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 12(%rsp)
	jg	.L10
.L11:
	movq	3320(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L28
	addq	$3328, %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
.L28:
	.cfi_restore_state
	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:
```