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>
#define kameisannnnn09 long long int
int main(void) {
    int n;
    static char s[100000][101];
    scanf("%d", &n);
    for (int i = 0; i < n; i++) {
        scanf("%s", s[i]);
    }

    kameisannnnn09 c[5] = {};
    for (int i = 0; i < n; i++) {
        if (s[i][0] == 'M') {
            c[0]++;
        }
        if (s[i][0] == 'A') {
            c[1]++;
        }
        if (s[i][0] == 'R') {
            c[2]++;
        }
        if (s[i][0] == 'C') {
            c[3]++;
        }
        if (s[i][0] == 'H') {
            c[4]++;
        }
    }
    // printf("cnt=%d %d %d %d %d\n", cm, ca, cr, cc, ch);
    kameisannnnn09 ans = 0;
    for (int i = 0; i < 3; i++) {
        for (int j = i + 1; j < 4; j++) {
            for (int k = j + 1; k < 5; k++) {
                ans += c[i] * c[j] * c[k];
            }
        }
    }
    printf("%lld\n", ans);
    return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
.LC2:
	.string	"%lld\n"
	.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	$80, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-80(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -76(%rbp)
	jmp	.L2
.L3:
	movl	-76(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	s.0(%rip), %rdx
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -76(%rbp)
.L2:
	movl	-80(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L3
	movq	$0, -48(%rbp)
	movq	$0, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, -24(%rbp)
	movq	$0, -16(%rbp)
	movl	$0, -72(%rbp)
	jmp	.L4
.L10:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$77, %al
	jne	.L5
	movq	-48(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -48(%rbp)
.L5:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$65, %al
	jne	.L6
	movq	-40(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -40(%rbp)
.L6:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$82, %al
	jne	.L7
	movq	-32(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -32(%rbp)
.L7:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$67, %al
	jne	.L8
	movq	-24(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -24(%rbp)
.L8:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$72, %al
	jne	.L9
	movq	-16(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -16(%rbp)
.L9:
	addl	$1, -72(%rbp)
.L4:
	movl	-80(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L10
	movq	$0, -56(%rbp)
	movl	$0, -68(%rbp)
	jmp	.L11
.L16:
	movl	-68(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -64(%rbp)
	jmp	.L12
.L15:
	movl	-64(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -60(%rbp)
	jmp	.L13
.L14:
	movl	-68(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rdx
	movl	-64(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rax
	imulq	%rax, %rdx
	movl	-60(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rax
	imulq	%rdx, %rax
	addq	%rax, -56(%rbp)
	addl	$1, -60(%rbp)
.L13:
	cmpl	$4, -60(%rbp)
	jle	.L14
	addl	$1, -64(%rbp)
.L12:
	cmpl	$3, -64(%rbp)
	jle	.L15
	addl	$1, -68(%rbp)
.L11:
	cmpl	$2, -68(%rbp)
	jle	.L16
	movq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L18
	call	__stack_chk_fail@PLT
.L18:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.local	s.0
	.comm	s.0,10100000,32
	.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	"%s"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	leaq	.LC0(%rip), %rdi
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$72, %rsp
	.cfi_def_cfa_offset 112
	movq	%fs:40, %rax
	movq	%rax, 56(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jle	.L2
	leaq	s.0(%rip), %rbx
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r13
	movq	%rbx, %r12
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addl	$1, %ebp
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	addq	$101, %r12
	cmpl	%ebp, %eax
	jg	.L3
	movq	$0, 48(%rsp)
	pxor	%xmm0, %xmm0
	movaps	%xmm0, 16(%rsp)
	movaps	%xmm0, 32(%rsp)
	testl	%eax, %eax
	jle	.L5
	subl	$1, %eax
	xorl	%r10d, %r10d
	xorl	%ecx, %ecx
	xorl	%r11d, %r11d
	leaq	(%rax,%rax,4), %rdx
	xorl	%esi, %esi
	xorl	%ebp, %ebp
	xorl	%edi, %edi
	leaq	(%rdx,%rdx,4), %rdx
	xorl	%r12d, %r12d
	xorl	%r8d, %r8d
	xorl	%r13d, %r13d
	leaq	(%rax,%rdx,4), %rdx
	leaq	101+s.0(%rip), %rax
	xorl	%r9d, %r9d
	addq	%rax, %rdx
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L6:
	cmpb	$65, %al
	je	.L8
	cmpb	$82, %al
	jne	.L9
	addq	$1, %rdi
	movl	$1, %ebp
.L7:
	addq	$101, %rbx
	cmpq	%rbx, %rdx
	je	.L38
.L11:
	movzbl	(%rbx), %eax
	cmpb	$77, %al
	jne	.L6
	addq	$101, %rbx
	addq	$1, %r9
	movl	$1, %r13d
	cmpq	%rbx, %rdx
	jne	.L11
.L38:
	testb	%r10b, %r10b
	je	.L12
	movq	%rcx, 48(%rsp)
.L12:
	testb	%r11b, %r11b
	je	.L13
	movq	%rsi, 40(%rsp)
.L13:
	testb	%bpl, %bpl
	je	.L14
	movq	%rdi, 32(%rsp)
.L14:
	testb	%r12b, %r12b
	je	.L15
	movq	%r8, 24(%rsp)
.L15:
	testb	%r13b, %r13b
	je	.L5
	movq	%r9, 16(%rsp)
.L5:
	movq	16(%rsp), %rcx
	movq	24(%rsp), %rdx
	movq	40(%rsp), %rax
	movq	32(%rsp), %r8
	movq	%rcx, %rdi
	movq	48(%rsp), %rsi
	imulq	%rdx, %rdi
	leaq	(%rax,%r8), %r9
	leaq	(%rsi,%r9), %r10
	movq	%rax, %r9
	imulq	%rdi, %r10
	movq	%r8, %rdi
	imulq	%rcx, %rdi
	imulq	%rax, %rcx
	imulq	%rdi, %r9
	imulq	%rsi, %rdi
	imulq	%rsi, %rcx
	addq	%r10, %r9
	addq	%r9, %rdi
	movq	%rax, %r9
	addq	%rdi, %rcx
	movq	%r8, %rdi
	imulq	%rdx, %rdi
	imulq	%rax, %rdx
	imulq	%r8, %rax
	imulq	%rdi, %r9
	imulq	%rsi, %rdi
	imulq	%rsi, %rdx
	imulq	%rsi, %rax
	addq	%r9, %rcx
	leaq	.LC2(%rip), %rsi
	addq	%rcx, %rdi
	addq	%rdi, %rdx
	movl	$1, %edi
	addq	%rax, %rdx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	56(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L39
	addq	$72, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L9:
	.cfi_restore_state
	cmpb	$67, %al
	jne	.L10
	addq	$1, %rsi
	movl	$1, %r11d
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L8:
	addq	$1, %r8
	movl	$1, %r12d
	jmp	.L7
.L10:
	cmpb	$72, %al
	jne	.L7
	addq	$1, %rcx
	movl	$1, %r10d
	jmp	.L7
.L2:
	leaq	16(%rsp), %rdi
	movl	$10, %ecx
	xorl	%eax, %eax
	rep stosl
	jmp	.L5
.L39:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.local	s.0
	.comm	s.0,10100000,32
	.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	"%s"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	leaq	.LC0(%rip), %rdi
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$72, %rsp
	.cfi_def_cfa_offset 112
	movq	%fs:40, %rax
	movq	%rax, 56(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jle	.L2
	leaq	s.0(%rip), %rbx
	xorl	%ebp, %ebp
	leaq	.LC1(%rip), %r13
	movq	%rbx, %r12
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%r12, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addl	$1, %ebp
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	addq	$101, %r12
	cmpl	%ebp, %eax
	jg	.L3
	movq	$0, 48(%rsp)
	pxor	%xmm0, %xmm0
	movaps	%xmm0, 16(%rsp)
	movaps	%xmm0, 32(%rsp)
	testl	%eax, %eax
	jle	.L5
	subl	$1, %eax
	xorl	%r10d, %r10d
	xorl	%ecx, %ecx
	xorl	%r11d, %r11d
	leaq	(%rax,%rax,4), %rdx
	xorl	%esi, %esi
	xorl	%ebp, %ebp
	xorl	%edi, %edi
	leaq	(%rdx,%rdx,4), %rdx
	xorl	%r12d, %r12d
	xorl	%r8d, %r8d
	xorl	%r13d, %r13d
	leaq	(%rax,%rdx,4), %rdx
	leaq	101+s.0(%rip), %rax
	xorl	%r9d, %r9d
	addq	%rax, %rdx
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L6:
	cmpb	$65, %al
	je	.L8
	cmpb	$82, %al
	jne	.L9
	addq	$1, %rdi
	movl	$1, %ebp
.L7:
	addq	$101, %rbx
	cmpq	%rbx, %rdx
	je	.L38
.L11:
	movzbl	(%rbx), %eax
	cmpb	$77, %al
	jne	.L6
	addq	$101, %rbx
	addq	$1, %r9
	movl	$1, %r13d
	cmpq	%rbx, %rdx
	jne	.L11
.L38:
	testb	%r10b, %r10b
	je	.L12
	movq	%rcx, 48(%rsp)
.L12:
	testb	%r11b, %r11b
	je	.L13
	movq	%rsi, 40(%rsp)
.L13:
	testb	%bpl, %bpl
	je	.L14
	movq	%rdi, 32(%rsp)
.L14:
	testb	%r12b, %r12b
	je	.L15
	movq	%r8, 24(%rsp)
.L15:
	testb	%r13b, %r13b
	je	.L5
	movq	%r9, 16(%rsp)
.L5:
	movq	16(%rsp), %rcx
	movq	24(%rsp), %rdx
	movq	40(%rsp), %rax
	movq	32(%rsp), %r8
	movq	%rcx, %rdi
	movq	48(%rsp), %rsi
	imulq	%rdx, %rdi
	leaq	(%rax,%r8), %r9
	leaq	(%rsi,%r9), %r10
	movq	%rax, %r9
	imulq	%rdi, %r10
	movq	%r8, %rdi
	imulq	%rcx, %rdi
	imulq	%rax, %rcx
	imulq	%rdi, %r9
	imulq	%rsi, %rdi
	imulq	%rsi, %rcx
	addq	%r10, %r9
	addq	%r9, %rdi
	movq	%rax, %r9
	addq	%rdi, %rcx
	movq	%r8, %rdi
	imulq	%rdx, %rdi
	imulq	%rax, %rdx
	imulq	%r8, %rax
	imulq	%rdi, %r9
	imulq	%rsi, %rdi
	imulq	%rsi, %rdx
	imulq	%rsi, %rax
	addq	%r9, %rcx
	leaq	.LC2(%rip), %rsi
	addq	%rcx, %rdi
	addq	%rdi, %rdx
	movl	$1, %edi
	addq	%rax, %rdx
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	56(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L39
	addq	$72, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L9:
	.cfi_restore_state
	cmpb	$67, %al
	jne	.L10
	addq	$1, %rsi
	movl	$1, %r11d
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L8:
	addq	$1, %r8
	movl	$1, %r12d
	jmp	.L7
.L10:
	cmpb	$72, %al
	jne	.L7
	addq	$1, %rcx
	movl	$1, %r10d
	jmp	.L7
.L2:
	leaq	16(%rsp), %rdi
	movl	$10, %ecx
	xorl	%eax, %eax
	rep stosl
	jmp	.L5
.L39:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.local	s.0
	.comm	s.0,10100000,32
	.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>
#define kameisannnnn09 long long int
int main(void) {
    int n;
    static char s[100000][101];
    scanf("%d", &n);
    for (int i = 0; i < n; i++) {
        scanf("%s", s[i]);
    }

    kameisannnnn09 c[5] = {};
    for (int i = 0; i < n; i++) {
        if (s[i][0] == 'M') {
            c[0]++;
        }
        if (s[i][0] == 'A') {
            c[1]++;
        }
        if (s[i][0] == 'R') {
            c[2]++;
        }
        if (s[i][0] == 'C') {
            c[3]++;
        }
        if (s[i][0] == 'H') {
            c[4]++;
        }
    }
    // printf("cnt=%d %d %d %d %d\n", cm, ca, cr, cc, ch);
    kameisannnnn09 ans = 0;
    for (int i = 0; i < 3; i++) {
        for (int j = i + 1; j < 4; j++) {
            for (int k = j + 1; k < 5; k++) {
                ans += c[i] * c[j] * c[k];
            }
        }
    }
    printf("%lld\n", ans);
    return 0;
}

5
MASHIKE
RUMOI
OBIRA
OROBAH
HOROKANAI
 5
CHOKUD@I
RNG
MAKOTO
AOKI
RINGO
 4
ZY
ZZZ
Z
ZZZZZZZZZZ
 5
DHOKUD@I
RNG
MAKOTO
AOKI
RINGN
 5
I@DUKOGE
HNR
MTAOKP
AINK
RINGN
 5
MASHIKE
IOMUR
OBIRA
OROBAH
HOROKANAI
 5
CHOKUD@I
RNG
MAKOTO
AOKI
RINGN
 4
ZY
ZZY
Z
ZZZZZZZZZZ
 5
MASHIKE
IOMUR
ARIBO
OROBAH
HOROKANAI
 4
ZY
YZZ
Z
ZZZZZZZZZZ

1
 7
 0
 2
 4
 0
 7
 0
 1
 0

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>
#define kameisannnnn09 long long int
int main(void) {
    int n;
    static char s[100000][101];
    scanf("%d", &n);
    for (int i = 0; i < n; i++) {
        scanf("%s", s[i]);
    }

    kameisannnnn09 c[5] = {};
    for (int i = 0; i < n; i++) {
        if (s[i][0] == 'M') {
            c[0]++;
        }
        if (s[i][0] == 'A') {
            c[1]++;
        }
        if (s[i][0] == 'R') {
            c[2]++;
        }
        if (s[i][0] == 'C') {
            c[3]++;
        }
        if (s[i][0] == 'H') {
            c[4]++;
        }
    }
    // printf("cnt=%d %d %d %d %d\n", cm, ca, cr, cc, ch);
    kameisannnnn09 ans = 0;
    for (int i = 0; i < 3; i++) {
        for (int j = i + 1; j < 4; j++) {
            for (int k = j + 1; k < 5; k++) {
                ans += c[i] * c[j] * c[k];
            }
        }
    }
    printf("%lld\n", ans);
    return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
.LC2:
	.string	"%lld\n"
	.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	$80, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-80(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -76(%rbp)
	jmp	.L2
.L3:
	movl	-76(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	s.0(%rip), %rdx
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -76(%rbp)
.L2:
	movl	-80(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L3
	movq	$0, -48(%rbp)
	movq	$0, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, -24(%rbp)
	movq	$0, -16(%rbp)
	movl	$0, -72(%rbp)
	jmp	.L4
.L10:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$77, %al
	jne	.L5
	movq	-48(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -48(%rbp)
.L5:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$65, %al
	jne	.L6
	movq	-40(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -40(%rbp)
.L6:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$82, %al
	jne	.L7
	movq	-32(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -32(%rbp)
.L7:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$67, %al
	jne	.L8
	movq	-24(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -24(%rbp)
.L8:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$72, %al
	jne	.L9
	movq	-16(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -16(%rbp)
.L9:
	addl	$1, -72(%rbp)
.L4:
	movl	-80(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L10
	movq	$0, -56(%rbp)
	movl	$0, -68(%rbp)
	jmp	.L11
.L16:
	movl	-68(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -64(%rbp)
	jmp	.L12
.L15:
	movl	-64(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -60(%rbp)
	jmp	.L13
.L14:
	movl	-68(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rdx
	movl	-64(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rax
	imulq	%rax, %rdx
	movl	-60(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rax
	imulq	%rdx, %rax
	addq	%rax, -56(%rbp)
	addl	$1, -60(%rbp)
.L13:
	cmpl	$4, -60(%rbp)
	jle	.L14
	addl	$1, -64(%rbp)
.L12:
	cmpl	$3, -64(%rbp)
	jle	.L15
	addl	$1, -68(%rbp)
.L11:
	cmpl	$2, -68(%rbp)
	jle	.L16
	movq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L18
	call	__stack_chk_fail@PLT
.L18:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.local	s.0
	.comm	s.0,10100000,32
	.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
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
.LC2:
	.string	"%lld\n"
	.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	$80, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-80(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -76(%rbp)
	jmp	.L2
.L3:
	movl	-76(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	s.0(%rip), %rdx
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -76(%rbp)
.L2:
	movl	-80(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L3
	movq	$0, -48(%rbp)
	movq	$0, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, -24(%rbp)
	movq	$0, -16(%rbp)
	movl	$0, -72(%rbp)
	jmp	.L4
.L10:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$77, %al
	jne	.L5
	movq	-48(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -48(%rbp)
.L5:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$65, %al
	jne	.L6
	movq	-40(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -40(%rbp)
.L6:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$82, %al
	jne	.L7
	movq	-32(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -32(%rbp)
.L7:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$67, %al
	jne	.L8
	movq	-24(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -24(%rbp)
.L8:
	movl	-72(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rcx
	addq	%rcx, %rax
	salq	$2, %rax
	addq	%rax, %rdx
	leaq	s.0(%rip), %rax
	movzbl	(%rdx,%rax), %eax
	cmpb	$72, %al
	jne	.L9
	movq	-16(%rbp), %rax
	addq	$1, %rax
	movq	%rax, -16(%rbp)
.L9:
	addl	$1, -72(%rbp)
.L4:
	movl	-80(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L10
	movq	$0, -56(%rbp)
	movl	$0, -68(%rbp)
	jmp	.L11
.L16:
	movl	-68(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -64(%rbp)
	jmp	.L12
.L15:
	movl	-64(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -60(%rbp)
	jmp	.L13
.L14:
	movl	-68(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rdx
	movl	-64(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rax
	imulq	%rax, %rdx
	movl	-60(%rbp), %eax
	cltq
	movq	-48(%rbp,%rax,8), %rax
	imulq	%rdx, %rax
	addq	%rax, -56(%rbp)
	addl	$1, -60(%rbp)
.L13:
	cmpl	$4, -60(%rbp)
	jle	.L14
	addl	$1, -64(%rbp)
.L12:
	cmpl	$3, -64(%rbp)
	jle	.L15
	addl	$1, -68(%rbp)
.L11:
	cmpl	$2, -68(%rbp)
	jle	.L16
	movq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L18
	call	__stack_chk_fail@PLT
.L18:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.local	s.0
	.comm	s.0,10100000,32
	.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:
