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>
#include <stdlib.h>
#include <math.h>

int main(void) {
    int H, W, K, i, j, k, l, sum, sc;
    char **masu, **masu2;
    int *nishin;

    sc = scanf("%d %d %d", &H, &W, &K);

    /*malloc--------------------------------------*/
    masu = (char **)malloc(sizeof(char *) * H);
    masu2 = (char **)malloc(sizeof(char *) * H);
    for(i = 0; i < H; i++) masu[i] = (char *)malloc(sizeof(char) * W);
    for(i = 0; i < H; i++) masu2[i] = (char *)malloc(sizeof(char) * W);
    nishin = (int *)malloc(sizeof(int) * (int)pow(2,H+W));
    /*malloc--------------------------------------*/

    for(i = 0; i < H; i++) sc = scanf("%s", masu[i]);

    for(i = 0; i < (int)pow(2,H+W); i++) nishin[i] = i;

    int cnt = 0;

    for(k = 0; k < (int)pow(2,H+W); k++){
        for(i = 0; i < H; i++){
            for(j = 0; j < W; j++){
                masu2[i][j] = masu[i][j];
            }
        }

        for(l = 0; l < H; l++){
            if((nishin[k] % 2) == 1){
                for(j = 0; j < W; j++){
                    masu2[l][j] = '.';
                }
            }
            nishin[k] /= 2;
        }

        for(l = 0; l < W; l++){
            if((nishin[k] % 2) == 1){
                for(i = 0; i < H; i++){
                    masu2[i][l] = '.';
                }
            }
            nishin[k] /= 2;
        }

        sum = 0;

        for(i = 0; i < H; i++){
            for(j = 0; j < W; j++){
                if(masu2[i][j] == '#') sum++;
            }
        }

        if(sum == K) cnt++;
    }

    printf("%d\n", cnt);

    /*free--------------------------------------*/
    free(nishin);
    for(i = H-1; i >= 0; i--) free(masu2[i]);
    for(i = H-1; i >= 0; i--) free(masu[i]);
    free(masu2);
    free(masu);
    /*free--------------------------------------*/

    return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d %d %d"
.LC2:
	.string	"%s"
.LC3:
	.string	"%d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$88, %rsp
	.cfi_offset 3, -24
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	leaq	-80(%rbp), %rcx
	leaq	-84(%rbp), %rdx
	leaq	-88(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, -52(%rbp)
	movl	-88(%rbp), %eax
	cltq
	salq	$3, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -48(%rbp)
	movl	-88(%rbp), %eax
	cltq
	salq	$3, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -40(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L2
.L3:
	movl	-84(%rbp), %eax
	cltq
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-48(%rbp), %rdx
	leaq	(%rcx,%rdx), %rbx
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, (%rbx)
	addl	$1, -76(%rbp)
.L2:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L3
	movl	$0, -76(%rbp)
	jmp	.L4
.L5:
	movl	-84(%rbp), %eax
	cltq
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-40(%rbp), %rdx
	leaq	(%rcx,%rdx), %rbx
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, (%rbx)
	addl	$1, -76(%rbp)
.L4:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L5
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cltq
	salq	$2, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -32(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L6
.L7:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, -52(%rbp)
	addl	$1, -76(%rbp)
.L6:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L7
	movl	$0, -76(%rbp)
	jmp	.L8
.L9:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rax, %rdx
	movl	-76(%rbp), %eax
	movl	%eax, (%rdx)
	addl	$1, -76(%rbp)
.L8:
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	%eax, -76(%rbp)
	jl	.L9
	movl	$0, -56(%rbp)
	movl	$0, -68(%rbp)
	jmp	.L10
.L31:
	movl	$0, -76(%rbp)
	jmp	.L11
.L14:
	movl	$0, -72(%rbp)
	jmp	.L12
.L13:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-40(%rbp), %rdx
	addq	%rcx, %rdx
	movq	(%rdx), %rcx
	movl	-72(%rbp), %edx
	movslq	%edx, %rdx
	addq	%rcx, %rdx
	movzbl	(%rax), %eax
	movb	%al, (%rdx)
	addl	$1, -72(%rbp)
.L12:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L13
	addl	$1, -76(%rbp)
.L11:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L14
	movl	$0, -64(%rbp)
	jmp	.L15
.L19:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	cltd
	shrl	$31, %edx
	addl	%edx, %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L16
	movl	$0, -72(%rbp)
	jmp	.L17
.L18:
	movl	-64(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movb	$46, (%rax)
	addl	$1, -72(%rbp)
.L17:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L18
.L16:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	movl	-68(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	movq	-32(%rbp), %rdx
	addq	%rcx, %rdx
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, (%rdx)
	addl	$1, -64(%rbp)
.L15:
	movl	-88(%rbp), %eax
	cmpl	%eax, -64(%rbp)
	jl	.L19
	movl	$0, -64(%rbp)
	jmp	.L20
.L24:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	cltd
	shrl	$31, %edx
	addl	%edx, %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L21
	movl	$0, -76(%rbp)
	jmp	.L22
.L23:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-64(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movb	$46, (%rax)
	addl	$1, -76(%rbp)
.L22:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L23
.L21:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	movl	-68(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	movq	-32(%rbp), %rdx
	addq	%rcx, %rdx
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, (%rdx)
	addl	$1, -64(%rbp)
.L20:
	movl	-84(%rbp), %eax
	cmpl	%eax, -64(%rbp)
	jl	.L24
	movl	$0, -60(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L25
.L29:
	movl	$0, -72(%rbp)
	jmp	.L26
.L28:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	jne	.L27
	addl	$1, -60(%rbp)
.L27:
	addl	$1, -72(%rbp)
.L26:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L28
	addl	$1, -76(%rbp)
.L25:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L29
	movl	-80(%rbp), %eax
	cmpl	%eax, -60(%rbp)
	jne	.L30
	addl	$1, -56(%rbp)
.L30:
	addl	$1, -68(%rbp)
.L10:
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	%eax, -68(%rbp)
	jl	.L31
	movl	-56(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movq	-32(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movl	-88(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	.L32
.L33:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rdi
	call	free@PLT
	subl	$1, -76(%rbp)
.L32:
	cmpl	$0, -76(%rbp)
	jns	.L33
	movl	-88(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	.L34
.L35:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rdi
	call	free@PLT
	subl	$1, -76(%rbp)
.L34:
	cmpl	$0, -76(%rbp)
	jns	.L35
	movq	-40(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movq	-48(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movl	$0, %eax
	movq	-24(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L37
	call	__stack_chk_fail@PLT
.L37:
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC1:
	.long	0
	.long	1073741824
	.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 %d %d"
.LC1:
	.string	"%s"
.LC5:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB39:
	.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	$136, %rsp
	.cfi_def_cfa_offset 192
	movq	%fs:40, %rax
	movq	%rax, 120(%rsp)
	xorl	%eax, %eax
	leaq	116(%rsp), %rcx
	leaq	112(%rsp), %rdx
	leaq	108(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movslq	108(%rsp), %rbp
	movl	%ebp, 20(%rsp)
	movq	%rbp, %rbx
	salq	$3, %rbp
	movq	%rbp, %rdi
	call	malloc@PLT
	movq	%rbp, %rdi
	movq	%rax, %r15
	call	malloc@PLT
	movq	%rax, %r13
	testl	%ebx, %ebx
	jle	.L2
	movl	%ebx, %eax
	movslq	112(%rsp), %rbx
	movq	%r15, %r14
	movl	%eax, %ebp
	movl	%ebx, 8(%rsp)
	salq	$3, %rbp
	leaq	0(%rbp,%r15), %r12
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rbx, %rdi
	addq	$8, %r14
	call	malloc@PLT
	movq	%rax, -8(%r14)
	cmpq	%r12, %r14
	jne	.L3
	movq	%r13, %r12
	addq	%r13, %rbp
	.p2align 4,,10
	.p2align 3
.L4:
	movq	%rbx, %rdi
	addq	$8, %r12
	call	malloc@PLT
	movq	%rax, -8(%r12)
	cmpq	%rbp, %r12
	jne	.L4
	movl	20(%rsp), %r14d
	pxor	%xmm1, %xmm1
	addl	8(%rsp), %r14d
	xorl	%ebp, %ebp
	cvtsi2sdl	%r14d, %xmm1
	movsd	.LC2(%rip), %xmm7
	leaq	.LC1(%rip), %rbx
	movapd	%xmm7, %xmm0
	movsd	%xmm7, 24(%rsp)
	call	pow@PLT
	cvttsd2sil	%xmm0, %edi
	movslq	%edi, %rdi
	salq	$2, %rdi
	call	malloc@PLT
	movq	%rax, 88(%rsp)
	.p2align 4,,10
	.p2align 3
.L6:
	movq	(%r15,%rbp,8), %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movl	108(%rsp), %eax
	cmpl	%ebp, %eax
	jg	.L6
	movl	%eax, 20(%rsp)
.L52:
	movl	112(%rsp), %r14d
	pxor	%xmm7, %xmm7
	movq	88(%rsp), %rbp
	xorl	%ebx, %ebx
	addl	%r14d, %eax
	cvtsi2sdl	%eax, %xmm7
	movsd	%xmm7, 56(%rsp)
	movapd	%xmm7, %xmm1
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L8:
	movl	%ebx, 0(%rbp,%rbx,4)
	addq	$1, %rbx
.L7:
	movsd	24(%rsp), %xmm0
	movsd	%xmm1, 8(%rsp)
	call	pow@PLT
	movsd	8(%rsp), %xmm1
	cvttsd2sil	%xmm0, %eax
	cmpl	%ebx, %eax
	jg	.L8
	movq	88(%rsp), %rax
	movl	$0, 72(%rsp)
	movl	$0, 36(%rsp)
	movq	%rax, 8(%rsp)
	movl	20(%rsp), %eax
	subl	$1, %eax
	leaq	8(%r13,%rax,8), %rbp
	movq	%rax, 80(%rsp)
	leal	-1(%r14), %eax
	movl	%eax, 32(%rsp)
	movl	%r14d, %eax
	movq	%rbp, %r12
	shrl	$4, %eax
	subl	$1, %eax
	movq	%rax, 64(%rsp)
	movl	%r14d, %eax
	andl	$-16, %eax
	movl	%eax, 76(%rsp)
	.p2align 4,,10
	.p2align 3
.L9:
	movsd	56(%rsp), %xmm1
	movsd	24(%rsp), %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	36(%rsp), %eax
	jle	.L46
	movl	20(%rsp), %eax
	movdqa	.LC3(%rip), %xmm5
	movdqa	.LC4(%rip), %xmm4
	testl	%eax, %eax
	jle	.L13
	movl	32(%rsp), %ebx
	xorl	%ebp, %ebp
	addq	$1, %rbx
	testl	%r14d, %r14d
	jle	.L47
	movq	%r12, 40(%rsp)
	movq	%rbx, %r12
	movq	80(%rsp), %rbx
	.p2align 4,,10
	.p2align 3
.L10:
	movq	0(%r13,%rbp,8), %rdi
	movq	(%r15,%rbp,8), %rsi
	movq	%r12, %rdx
	call	memcpy@PLT
	movq	%rbp, %rax
	addq	$1, %rbp
	movdqa	.LC3(%rip), %xmm5
	cmpq	%rax, %rbx
	movdqa	.LC4(%rip), %xmm4
	jne	.L10
	movq	40(%rsp), %r12
.L47:
	movq	8(%rsp), %rax
	movl	32(%rsp), %ebx
	movq	%r13, %rbp
	movq	%r15, 40(%rsp)
	movq	%r13, 48(%rsp)
	movl	%r14d, %r13d
	movq	%r12, %r14
	movq	%rbp, %r12
	movl	(%rax), %ecx
	movq	%rbx, %rbp
	movq	%rax, %r15
	movl	%ecx, %ebx
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L14:
	movl	%ebx, %eax
	addq	$8, %r12
	shrl	$31, %eax
	addl	%ebx, %eax
	sarl	%eax
	movl	%eax, (%r15)
	movl	%eax, %ebx
	cmpq	%r14, %r12
	je	.L78
.L12:
	movl	%ebx, %edx
	shrl	$31, %edx
	leal	(%rbx,%rdx), %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L14
	testl	%r13d, %r13d
	jle	.L14
	movq	(%r12), %rdi
	leaq	1(%rbp), %rdx
	movl	$46, %esi
	call	memset@PLT
	movdqa	.LC3(%rip), %xmm5
	movdqa	.LC4(%rip), %xmm4
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L78:
	movq	%r14, %r12
	movq	40(%rsp), %r15
	movl	%r13d, %r14d
	movq	48(%rsp), %r13
.L13:
	testl	%r14d, %r14d
	jle	.L23
	movq	8(%rsp), %rax
	movl	32(%rsp), %ebx
	xorl	%esi, %esi
	movl	(%rax), %edx
	movl	%edx, %eax
	jmp	.L19
	.p2align 4,,10
	.p2align 3
.L21:
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	leaq	1(%rsi), %rcx
	sarl	%eax
	cmpq	%rbx, %rsi
	je	.L79
	movq	%rcx, %rsi
.L19:
	movl	%eax, %edi
	shrl	$31, %edi
	leal	(%rax,%rdi), %ecx
	andl	$1, %ecx
	subl	%edi, %ecx
	cmpl	$1, %ecx
	jne	.L21
	movl	20(%rsp), %ecx
	testl	%ecx, %ecx
	jle	.L21
	movq	%r13, %rcx
	.p2align 4,,10
	.p2align 3
.L22:
	movq	(%rcx), %rdi
	addq	$8, %rcx
	movb	$46, (%rdi,%rsi)
	cmpq	%r12, %rcx
	jne	.L22
	jmp	.L21
	.p2align 4,,10
	.p2align 3
.L79:
	xorl	%ecx, %ecx
	.p2align 4,,10
	.p2align 3
.L20:
	movl	%edx, %eax
	addl	$1, %ecx
	shrl	$31, %eax
	addl	%eax, %edx
	sarl	%edx
	cmpl	%r14d, %ecx
	jne	.L20
	movq	8(%rsp), %rax
	movl	%edx, (%rax)
.L23:
	movl	20(%rsp), %edi
	movq	%r13, %rsi
	xorl	%edx, %edx
	testl	%edi, %edi
	jle	.L17
	movq	64(%rsp), %rax
	movl	76(%rsp), %r9d
	pxor	%xmm7, %xmm7
	pxor	%xmm6, %xmm6
	movl	32(%rsp), %r10d
	leaq	1(%rax), %rdi
	salq	$4, %rdi
	.p2align 4,,10
	.p2align 3
.L16:
	testl	%r14d, %r14d
	jle	.L44
	movq	(%rsi), %rcx
	cmpl	$14, %r10d
	jbe	.L56
	movq	%rcx, %rax
	leaq	(%rdi,%rcx), %r8
	pxor	%xmm1, %xmm1
	.p2align 4,,10
	.p2align 3
.L25:
	movdqu	(%rax), %xmm0
	movdqa	%xmm7, %xmm2
	movdqa	%xmm6, %xmm8
	addq	$16, %rax
	pcmpeqb	%xmm5, %xmm0
	pand	%xmm4, %xmm0
	pcmpgtb	%xmm0, %xmm2
	movdqa	%xmm0, %xmm3
	punpcklbw	%xmm2, %xmm3
	punpckhbw	%xmm2, %xmm0
	pcmpgtw	%xmm3, %xmm8
	movdqa	%xmm3, %xmm2
	punpcklwd	%xmm8, %xmm2
	punpckhwd	%xmm8, %xmm3
	paddd	%xmm2, %xmm1
	movdqa	%xmm6, %xmm2
	pcmpgtw	%xmm0, %xmm2
	paddd	%xmm3, %xmm1
	movdqa	%xmm0, %xmm3
	punpcklwd	%xmm2, %xmm3
	punpckhwd	%xmm2, %xmm0
	paddd	%xmm3, %xmm1
	paddd	%xmm0, %xmm1
	cmpq	%r8, %rax
	jne	.L25
	movdqa	%xmm1, %xmm0
	psrldq	$8, %xmm0
	paddd	%xmm0, %xmm1
	movdqa	%xmm1, %xmm0
	psrldq	$4, %xmm0
	paddd	%xmm0, %xmm1
	movd	%xmm1, %eax
	addl	%eax, %edx
	cmpl	%r9d, %r14d
	je	.L44
	movl	%r9d, %eax
.L24:
	movslq	%eax, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	1(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	2(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	3(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	4(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	5(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	6(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	7(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	8(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	9(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	10(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	11(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	12(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	13(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	addl	$14, %eax
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	cmpl	%eax, %r14d
	jle	.L44
	cltq
	cmpb	$35, (%rcx,%rax)
	sete	%al
	movzbl	%al, %eax
	addl	%eax, %edx
	.p2align 4,,10
	.p2align 3
.L44:
	addq	$8, %rsi
	cmpq	%r12, %rsi
	jne	.L16
.L17:
	xorl	%eax, %eax
	cmpl	%edx, 116(%rsp)
	sete	%al
	addl	$1, 36(%rsp)
	addl	%eax, 72(%rsp)
	addq	$4, 8(%rsp)
	jmp	.L9
.L56:
	xorl	%eax, %eax
	jmp	.L24
.L46:
	movl	72(%rsp), %edx
	leaq	.LC5(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	88(%rsp), %rdi
	call	free@PLT
	movl	108(%rsp), %eax
	subl	$1, %eax
	movslq	%eax, %rbx
	movq	%rbx, %rbp
	js	.L51
	.p2align 4,,10
	.p2align 3
.L49:
	movq	0(%r13,%rbp,8), %rdi
	subq	$1, %rbp
	call	free@PLT
	testl	%ebp, %ebp
	jns	.L49
	.p2align 4,,10
	.p2align 3
.L50:
	movq	(%r15,%rbx,8), %rdi
	subq	$1, %rbx
	call	free@PLT
	testl	%ebx, %ebx
	jns	.L50
.L51:
	movq	%r13, %rdi
	call	free@PLT
	movq	%r15, %rdi
	call	free@PLT
	movq	120(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L80
	addq	$136, %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
.L2:
	.cfi_restore_state
	movl	20(%rsp), %eax
	pxor	%xmm1, %xmm1
	addl	112(%rsp), %eax
	cvtsi2sdl	%eax, %xmm1
	movsd	.LC2(%rip), %xmm7
	movapd	%xmm7, %xmm0
	movsd	%xmm7, 24(%rsp)
	call	pow@PLT
	cvttsd2sil	%xmm0, %edi
	movslq	%edi, %rdi
	salq	$2, %rdi
	call	malloc@PLT
	movq	%rax, 88(%rsp)
	movl	20(%rsp), %eax
	jmp	.L52
.L80:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.size	main, .-main
	.section	.rodata.cst8,"aM",@progbits,8
	.align 8
.LC2:
	.long	0
	.long	1073741824
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC3:
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.align 16
.LC4:
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.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 %d %d"
.LC1:
	.string	"%s"
.LC5:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB39:
	.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	$136, %rsp
	.cfi_def_cfa_offset 192
	movq	%fs:40, %rax
	movq	%rax, 120(%rsp)
	xorl	%eax, %eax
	leaq	116(%rsp), %rcx
	leaq	112(%rsp), %rdx
	leaq	108(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movslq	108(%rsp), %rbp
	movl	%ebp, 20(%rsp)
	movq	%rbp, %rbx
	salq	$3, %rbp
	movq	%rbp, %rdi
	call	malloc@PLT
	movq	%rbp, %rdi
	movq	%rax, %r15
	call	malloc@PLT
	movq	%rax, %r13
	testl	%ebx, %ebx
	jle	.L2
	movl	%ebx, %eax
	movslq	112(%rsp), %rbx
	movq	%r15, %r14
	movl	%eax, %ebp
	movl	%ebx, 8(%rsp)
	salq	$3, %rbp
	leaq	0(%rbp,%r15), %r12
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rbx, %rdi
	addq	$8, %r14
	call	malloc@PLT
	movq	%rax, -8(%r14)
	cmpq	%r12, %r14
	jne	.L3
	movq	%r13, %r12
	addq	%r13, %rbp
	.p2align 4,,10
	.p2align 3
.L4:
	movq	%rbx, %rdi
	addq	$8, %r12
	call	malloc@PLT
	movq	%rax, -8(%r12)
	cmpq	%rbp, %r12
	jne	.L4
	movl	20(%rsp), %r14d
	pxor	%xmm1, %xmm1
	addl	8(%rsp), %r14d
	xorl	%ebp, %ebp
	cvtsi2sdl	%r14d, %xmm1
	movsd	.LC2(%rip), %xmm7
	leaq	.LC1(%rip), %rbx
	movapd	%xmm7, %xmm0
	movsd	%xmm7, 24(%rsp)
	call	pow@PLT
	cvttsd2sil	%xmm0, %edi
	movslq	%edi, %rdi
	salq	$2, %rdi
	call	malloc@PLT
	movq	%rax, 88(%rsp)
	.p2align 4,,10
	.p2align 3
.L6:
	movq	(%r15,%rbp,8), %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__isoc99_scanf@PLT
	movl	108(%rsp), %eax
	cmpl	%ebp, %eax
	jg	.L6
	movl	%eax, 20(%rsp)
.L52:
	movl	112(%rsp), %r14d
	pxor	%xmm7, %xmm7
	movq	88(%rsp), %rbp
	xorl	%ebx, %ebx
	addl	%r14d, %eax
	cvtsi2sdl	%eax, %xmm7
	movsd	%xmm7, 56(%rsp)
	movapd	%xmm7, %xmm1
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L8:
	movl	%ebx, 0(%rbp,%rbx,4)
	addq	$1, %rbx
.L7:
	movsd	24(%rsp), %xmm0
	movsd	%xmm1, 8(%rsp)
	call	pow@PLT
	movsd	8(%rsp), %xmm1
	cvttsd2sil	%xmm0, %eax
	cmpl	%ebx, %eax
	jg	.L8
	movq	88(%rsp), %rax
	movl	$0, 72(%rsp)
	movl	$0, 36(%rsp)
	movq	%rax, 8(%rsp)
	movl	20(%rsp), %eax
	subl	$1, %eax
	leaq	8(%r13,%rax,8), %rbp
	movq	%rax, 80(%rsp)
	leal	-1(%r14), %eax
	movl	%eax, 32(%rsp)
	movl	%r14d, %eax
	movq	%rbp, %r12
	shrl	$4, %eax
	subl	$1, %eax
	movq	%rax, 64(%rsp)
	movl	%r14d, %eax
	andl	$-16, %eax
	movl	%eax, 76(%rsp)
	.p2align 4,,10
	.p2align 3
.L9:
	movsd	56(%rsp), %xmm1
	movsd	24(%rsp), %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	36(%rsp), %eax
	jle	.L46
	movl	20(%rsp), %eax
	movdqa	.LC3(%rip), %xmm5
	movdqa	.LC4(%rip), %xmm4
	testl	%eax, %eax
	jle	.L13
	movl	32(%rsp), %ebx
	xorl	%ebp, %ebp
	addq	$1, %rbx
	testl	%r14d, %r14d
	jle	.L47
	movq	%r12, 40(%rsp)
	movq	%rbx, %r12
	movq	80(%rsp), %rbx
	.p2align 4,,10
	.p2align 3
.L10:
	movq	0(%r13,%rbp,8), %rdi
	movq	(%r15,%rbp,8), %rsi
	movq	%r12, %rdx
	call	memcpy@PLT
	movq	%rbp, %rax
	addq	$1, %rbp
	movdqa	.LC3(%rip), %xmm5
	cmpq	%rax, %rbx
	movdqa	.LC4(%rip), %xmm4
	jne	.L10
	movq	40(%rsp), %r12
.L47:
	movq	8(%rsp), %rax
	movl	32(%rsp), %ebx
	movq	%r13, %rbp
	movq	%r15, 40(%rsp)
	movq	%r13, 48(%rsp)
	movl	%r14d, %r13d
	movq	%r12, %r14
	movq	%rbp, %r12
	movl	(%rax), %ecx
	movq	%rbx, %rbp
	movq	%rax, %r15
	movl	%ecx, %ebx
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L14:
	movl	%ebx, %eax
	addq	$8, %r12
	shrl	$31, %eax
	addl	%ebx, %eax
	sarl	%eax
	movl	%eax, (%r15)
	movl	%eax, %ebx
	cmpq	%r14, %r12
	je	.L78
.L12:
	movl	%ebx, %edx
	shrl	$31, %edx
	leal	(%rbx,%rdx), %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L14
	testl	%r13d, %r13d
	jle	.L14
	movq	(%r12), %rdi
	leaq	1(%rbp), %rdx
	movl	$46, %esi
	call	memset@PLT
	movdqa	.LC3(%rip), %xmm5
	movdqa	.LC4(%rip), %xmm4
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L78:
	movq	%r14, %r12
	movq	40(%rsp), %r15
	movl	%r13d, %r14d
	movq	48(%rsp), %r13
.L13:
	testl	%r14d, %r14d
	jle	.L23
	movq	8(%rsp), %rax
	movl	32(%rsp), %ebx
	xorl	%esi, %esi
	movl	(%rax), %edx
	movl	%edx, %eax
	jmp	.L19
	.p2align 4,,10
	.p2align 3
.L21:
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	leaq	1(%rsi), %rcx
	sarl	%eax
	cmpq	%rbx, %rsi
	je	.L79
	movq	%rcx, %rsi
.L19:
	movl	%eax, %edi
	shrl	$31, %edi
	leal	(%rax,%rdi), %ecx
	andl	$1, %ecx
	subl	%edi, %ecx
	cmpl	$1, %ecx
	jne	.L21
	movl	20(%rsp), %ecx
	testl	%ecx, %ecx
	jle	.L21
	movq	%r13, %rcx
	.p2align 4,,10
	.p2align 3
.L22:
	movq	(%rcx), %rdi
	addq	$8, %rcx
	movb	$46, (%rdi,%rsi)
	cmpq	%r12, %rcx
	jne	.L22
	jmp	.L21
	.p2align 4,,10
	.p2align 3
.L79:
	xorl	%ecx, %ecx
	.p2align 4,,10
	.p2align 3
.L20:
	movl	%edx, %eax
	addl	$1, %ecx
	shrl	$31, %eax
	addl	%eax, %edx
	sarl	%edx
	cmpl	%r14d, %ecx
	jne	.L20
	movq	8(%rsp), %rax
	movl	%edx, (%rax)
.L23:
	movl	20(%rsp), %edi
	movq	%r13, %rsi
	xorl	%edx, %edx
	testl	%edi, %edi
	jle	.L17
	movq	64(%rsp), %rax
	movl	76(%rsp), %r9d
	pxor	%xmm7, %xmm7
	pxor	%xmm6, %xmm6
	movl	32(%rsp), %r10d
	leaq	1(%rax), %rdi
	salq	$4, %rdi
	.p2align 4,,10
	.p2align 3
.L16:
	testl	%r14d, %r14d
	jle	.L44
	movq	(%rsi), %rcx
	cmpl	$14, %r10d
	jbe	.L56
	movq	%rcx, %rax
	leaq	(%rdi,%rcx), %r8
	pxor	%xmm1, %xmm1
	.p2align 4,,10
	.p2align 3
.L25:
	movdqu	(%rax), %xmm0
	movdqa	%xmm7, %xmm2
	movdqa	%xmm6, %xmm8
	addq	$16, %rax
	pcmpeqb	%xmm5, %xmm0
	pand	%xmm4, %xmm0
	pcmpgtb	%xmm0, %xmm2
	movdqa	%xmm0, %xmm3
	punpcklbw	%xmm2, %xmm3
	punpckhbw	%xmm2, %xmm0
	pcmpgtw	%xmm3, %xmm8
	movdqa	%xmm3, %xmm2
	punpcklwd	%xmm8, %xmm2
	punpckhwd	%xmm8, %xmm3
	paddd	%xmm2, %xmm1
	movdqa	%xmm6, %xmm2
	pcmpgtw	%xmm0, %xmm2
	paddd	%xmm3, %xmm1
	movdqa	%xmm0, %xmm3
	punpcklwd	%xmm2, %xmm3
	punpckhwd	%xmm2, %xmm0
	paddd	%xmm3, %xmm1
	paddd	%xmm0, %xmm1
	cmpq	%r8, %rax
	jne	.L25
	movdqa	%xmm1, %xmm0
	psrldq	$8, %xmm0
	paddd	%xmm0, %xmm1
	movdqa	%xmm1, %xmm0
	psrldq	$4, %xmm0
	paddd	%xmm0, %xmm1
	movd	%xmm1, %eax
	addl	%eax, %edx
	cmpl	%r9d, %r14d
	je	.L44
	movl	%r9d, %eax
.L24:
	movslq	%eax, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	1(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	2(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	3(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	4(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	5(%rax), %r8d
	cmpl	%r14d, %r8d
	jge	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	6(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	7(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	8(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	9(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	10(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	11(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	12(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	leal	13(%rax), %r8d
	cmpl	%r8d, %r14d
	jle	.L44
	movslq	%r8d, %r8
	cmpb	$35, (%rcx,%r8)
	sete	%r8b
	addl	$14, %eax
	movzbl	%r8b, %r8d
	addl	%r8d, %edx
	cmpl	%eax, %r14d
	jle	.L44
	cltq
	cmpb	$35, (%rcx,%rax)
	sete	%al
	movzbl	%al, %eax
	addl	%eax, %edx
	.p2align 4,,10
	.p2align 3
.L44:
	addq	$8, %rsi
	cmpq	%r12, %rsi
	jne	.L16
.L17:
	xorl	%eax, %eax
	cmpl	%edx, 116(%rsp)
	sete	%al
	addl	$1, 36(%rsp)
	addl	%eax, 72(%rsp)
	addq	$4, 8(%rsp)
	jmp	.L9
.L56:
	xorl	%eax, %eax
	jmp	.L24
.L46:
	movl	72(%rsp), %edx
	leaq	.LC5(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movq	88(%rsp), %rdi
	call	free@PLT
	movl	108(%rsp), %eax
	subl	$1, %eax
	movslq	%eax, %rbx
	movq	%rbx, %rbp
	js	.L51
	.p2align 4,,10
	.p2align 3
.L49:
	movq	0(%r13,%rbp,8), %rdi
	subq	$1, %rbp
	call	free@PLT
	testl	%ebp, %ebp
	jns	.L49
	.p2align 4,,10
	.p2align 3
.L50:
	movq	(%r15,%rbx,8), %rdi
	subq	$1, %rbx
	call	free@PLT
	testl	%ebx, %ebx
	jns	.L50
.L51:
	movq	%r13, %rdi
	call	free@PLT
	movq	%r15, %rdi
	call	free@PLT
	movq	120(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L80
	addq	$136, %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
.L2:
	.cfi_restore_state
	movl	20(%rsp), %eax
	pxor	%xmm1, %xmm1
	addl	112(%rsp), %eax
	cvtsi2sdl	%eax, %xmm1
	movsd	.LC2(%rip), %xmm7
	movapd	%xmm7, %xmm0
	movsd	%xmm7, 24(%rsp)
	call	pow@PLT
	cvttsd2sil	%xmm0, %edi
	movslq	%edi, %rdi
	salq	$2, %rdi
	call	malloc@PLT
	movq	%rax, 88(%rsp)
	movl	20(%rsp), %eax
	jmp	.L52
.L80:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE39:
	.size	main, .-main
	.section	.rodata.cst8,"aM",@progbits,8
	.align 8
.LC2:
	.long	0
	.long	1073741824
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC3:
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.byte	35
	.align 16
.LC4:
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.byte	1
	.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>
#include <stdlib.h>
#include <math.h>

int main(void) {
    int H, W, K, i, j, k, l, sum, sc;
    char **masu, **masu2;
    int *nishin;

    sc = scanf("%d %d %d", &H, &W, &K);

    /*malloc--------------------------------------*/
    masu = (char **)malloc(sizeof(char *) * H);
    masu2 = (char **)malloc(sizeof(char *) * H);
    for(i = 0; i < H; i++) masu[i] = (char *)malloc(sizeof(char) * W);
    for(i = 0; i < H; i++) masu2[i] = (char *)malloc(sizeof(char) * W);
    nishin = (int *)malloc(sizeof(int) * (int)pow(2,H+W));
    /*malloc--------------------------------------*/

    for(i = 0; i < H; i++) sc = scanf("%s", masu[i]);

    for(i = 0; i < (int)pow(2,H+W); i++) nishin[i] = i;

    int cnt = 0;

    for(k = 0; k < (int)pow(2,H+W); k++){
        for(i = 0; i < H; i++){
            for(j = 0; j < W; j++){
                masu2[i][j] = masu[i][j];
            }
        }

        for(l = 0; l < H; l++){
            if((nishin[k] % 2) == 1){
                for(j = 0; j < W; j++){
                    masu2[l][j] = '.';
                }
            }
            nishin[k] /= 2;
        }

        for(l = 0; l < W; l++){
            if((nishin[k] % 2) == 1){
                for(i = 0; i < H; i++){
                    masu2[i][l] = '.';
                }
            }
            nishin[k] /= 2;
        }

        sum = 0;

        for(i = 0; i < H; i++){
            for(j = 0; j < W; j++){
                if(masu2[i][j] == '#') sum++;
            }
        }

        if(sum == K) cnt++;
    }

    printf("%d\n", cnt);

    /*free--------------------------------------*/
    free(nishin);
    for(i = H-1; i >= 0; i--) free(masu2[i]);
    for(i = H-1; i >= 0; i--) free(masu[i]);
    free(masu2);
    free(masu);
    /*free--------------------------------------*/

    return 0;
}
2 2 4
..#
 4 3 2
..#
###
 4 3 2
..#
$##
 2 3 0
.-#
 3 3 0
/,#
 6 3 0
/,#
 6 3 1
/,#
 6 3 0
/,$
 6 2 0
/,$
 1 4 0

0
 20
 16
 24
 48
 384
 128
 512
 256
 32

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>
#include <stdlib.h>
#include <math.h>

int main(void) {
    int H, W, K, i, j, k, l, sum, sc;
    char **masu, **masu2;
    int *nishin;

    sc = scanf("%d %d %d", &H, &W, &K);

    /*malloc--------------------------------------*/
    masu = (char **)malloc(sizeof(char *) * H);
    masu2 = (char **)malloc(sizeof(char *) * H);
    for(i = 0; i < H; i++) masu[i] = (char *)malloc(sizeof(char) * W);
    for(i = 0; i < H; i++) masu2[i] = (char *)malloc(sizeof(char) * W);
    nishin = (int *)malloc(sizeof(int) * (int)pow(2,H+W));
    /*malloc--------------------------------------*/

    for(i = 0; i < H; i++) sc = scanf("%s", masu[i]);

    for(i = 0; i < (int)pow(2,H+W); i++) nishin[i] = i;

    int cnt = 0;

    for(k = 0; k < (int)pow(2,H+W); k++){
        for(i = 0; i < H; i++){
            for(j = 0; j < W; j++){
                masu2[i][j] = masu[i][j];
            }
        }

        for(l = 0; l < H; l++){
            if((nishin[k] % 2) == 1){
                for(j = 0; j < W; j++){
                    masu2[l][j] = '.';
                }
            }
            nishin[k] /= 2;
        }

        for(l = 0; l < W; l++){
            if((nishin[k] % 2) == 1){
                for(i = 0; i < H; i++){
                    masu2[i][l] = '.';
                }
            }
            nishin[k] /= 2;
        }

        sum = 0;

        for(i = 0; i < H; i++){
            for(j = 0; j < W; j++){
                if(masu2[i][j] == '#') sum++;
            }
        }

        if(sum == K) cnt++;
    }

    printf("%d\n", cnt);

    /*free--------------------------------------*/
    free(nishin);
    for(i = H-1; i >= 0; i--) free(masu2[i]);
    for(i = H-1; i >= 0; i--) free(masu[i]);
    free(masu2);
    free(masu);
    /*free--------------------------------------*/

    return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d %d %d"
.LC2:
	.string	"%s"
.LC3:
	.string	"%d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$88, %rsp
	.cfi_offset 3, -24
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	leaq	-80(%rbp), %rcx
	leaq	-84(%rbp), %rdx
	leaq	-88(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, -52(%rbp)
	movl	-88(%rbp), %eax
	cltq
	salq	$3, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -48(%rbp)
	movl	-88(%rbp), %eax
	cltq
	salq	$3, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -40(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L2
.L3:
	movl	-84(%rbp), %eax
	cltq
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-48(%rbp), %rdx
	leaq	(%rcx,%rdx), %rbx
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, (%rbx)
	addl	$1, -76(%rbp)
.L2:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L3
	movl	$0, -76(%rbp)
	jmp	.L4
.L5:
	movl	-84(%rbp), %eax
	cltq
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-40(%rbp), %rdx
	leaq	(%rcx,%rdx), %rbx
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, (%rbx)
	addl	$1, -76(%rbp)
.L4:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L5
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cltq
	salq	$2, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -32(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L6
.L7:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, -52(%rbp)
	addl	$1, -76(%rbp)
.L6:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L7
	movl	$0, -76(%rbp)
	jmp	.L8
.L9:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rax, %rdx
	movl	-76(%rbp), %eax
	movl	%eax, (%rdx)
	addl	$1, -76(%rbp)
.L8:
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	%eax, -76(%rbp)
	jl	.L9
	movl	$0, -56(%rbp)
	movl	$0, -68(%rbp)
	jmp	.L10
.L31:
	movl	$0, -76(%rbp)
	jmp	.L11
.L14:
	movl	$0, -72(%rbp)
	jmp	.L12
.L13:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-40(%rbp), %rdx
	addq	%rcx, %rdx
	movq	(%rdx), %rcx
	movl	-72(%rbp), %edx
	movslq	%edx, %rdx
	addq	%rcx, %rdx
	movzbl	(%rax), %eax
	movb	%al, (%rdx)
	addl	$1, -72(%rbp)
.L12:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L13
	addl	$1, -76(%rbp)
.L11:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L14
	movl	$0, -64(%rbp)
	jmp	.L15
.L19:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	cltd
	shrl	$31, %edx
	addl	%edx, %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L16
	movl	$0, -72(%rbp)
	jmp	.L17
.L18:
	movl	-64(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movb	$46, (%rax)
	addl	$1, -72(%rbp)
.L17:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L18
.L16:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	movl	-68(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	movq	-32(%rbp), %rdx
	addq	%rcx, %rdx
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, (%rdx)
	addl	$1, -64(%rbp)
.L15:
	movl	-88(%rbp), %eax
	cmpl	%eax, -64(%rbp)
	jl	.L19
	movl	$0, -64(%rbp)
	jmp	.L20
.L24:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	cltd
	shrl	$31, %edx
	addl	%edx, %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L21
	movl	$0, -76(%rbp)
	jmp	.L22
.L23:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-64(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movb	$46, (%rax)
	addl	$1, -76(%rbp)
.L22:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L23
.L21:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	movl	-68(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	movq	-32(%rbp), %rdx
	addq	%rcx, %rdx
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, (%rdx)
	addl	$1, -64(%rbp)
.L20:
	movl	-84(%rbp), %eax
	cmpl	%eax, -64(%rbp)
	jl	.L24
	movl	$0, -60(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L25
.L29:
	movl	$0, -72(%rbp)
	jmp	.L26
.L28:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	jne	.L27
	addl	$1, -60(%rbp)
.L27:
	addl	$1, -72(%rbp)
.L26:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L28
	addl	$1, -76(%rbp)
.L25:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L29
	movl	-80(%rbp), %eax
	cmpl	%eax, -60(%rbp)
	jne	.L30
	addl	$1, -56(%rbp)
.L30:
	addl	$1, -68(%rbp)
.L10:
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	%eax, -68(%rbp)
	jl	.L31
	movl	-56(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movq	-32(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movl	-88(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	.L32
.L33:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rdi
	call	free@PLT
	subl	$1, -76(%rbp)
.L32:
	cmpl	$0, -76(%rbp)
	jns	.L33
	movl	-88(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	.L34
.L35:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rdi
	call	free@PLT
	subl	$1, -76(%rbp)
.L34:
	cmpl	$0, -76(%rbp)
	jns	.L35
	movq	-40(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movq	-48(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movl	$0, %eax
	movq	-24(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L37
	call	__stack_chk_fail@PLT
.L37:
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC1:
	.long	0
	.long	1073741824
	.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 %d %d"
.LC2:
	.string	"%s"
.LC3:
	.string	"%d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$88, %rsp
	.cfi_offset 3, -24
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	leaq	-80(%rbp), %rcx
	leaq	-84(%rbp), %rdx
	leaq	-88(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, -52(%rbp)
	movl	-88(%rbp), %eax
	cltq
	salq	$3, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -48(%rbp)
	movl	-88(%rbp), %eax
	cltq
	salq	$3, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -40(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L2
.L3:
	movl	-84(%rbp), %eax
	cltq
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-48(%rbp), %rdx
	leaq	(%rcx,%rdx), %rbx
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, (%rbx)
	addl	$1, -76(%rbp)
.L2:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L3
	movl	$0, -76(%rbp)
	jmp	.L4
.L5:
	movl	-84(%rbp), %eax
	cltq
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-40(%rbp), %rdx
	leaq	(%rcx,%rdx), %rbx
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, (%rbx)
	addl	$1, -76(%rbp)
.L4:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L5
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cltq
	salq	$2, %rax
	movq	%rax, %rdi
	call	malloc@PLT
	movq	%rax, -32(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L6
.L7:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	%eax, -52(%rbp)
	addl	$1, -76(%rbp)
.L6:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L7
	movl	$0, -76(%rbp)
	jmp	.L8
.L9:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rax, %rdx
	movl	-76(%rbp), %eax
	movl	%eax, (%rdx)
	addl	$1, -76(%rbp)
.L8:
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	%eax, -76(%rbp)
	jl	.L9
	movl	$0, -56(%rbp)
	movl	$0, -68(%rbp)
	jmp	.L10
.L31:
	movl	$0, -76(%rbp)
	jmp	.L11
.L14:
	movl	$0, -72(%rbp)
	jmp	.L12
.L13:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movl	-76(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	movq	-40(%rbp), %rdx
	addq	%rcx, %rdx
	movq	(%rdx), %rcx
	movl	-72(%rbp), %edx
	movslq	%edx, %rdx
	addq	%rcx, %rdx
	movzbl	(%rax), %eax
	movb	%al, (%rdx)
	addl	$1, -72(%rbp)
.L12:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L13
	addl	$1, -76(%rbp)
.L11:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L14
	movl	$0, -64(%rbp)
	jmp	.L15
.L19:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	cltd
	shrl	$31, %edx
	addl	%edx, %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L16
	movl	$0, -72(%rbp)
	jmp	.L17
.L18:
	movl	-64(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movb	$46, (%rax)
	addl	$1, -72(%rbp)
.L17:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L18
.L16:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	movl	-68(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	movq	-32(%rbp), %rdx
	addq	%rcx, %rdx
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, (%rdx)
	addl	$1, -64(%rbp)
.L15:
	movl	-88(%rbp), %eax
	cmpl	%eax, -64(%rbp)
	jl	.L19
	movl	$0, -64(%rbp)
	jmp	.L20
.L24:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	cltd
	shrl	$31, %edx
	addl	%edx, %eax
	andl	$1, %eax
	subl	%edx, %eax
	cmpl	$1, %eax
	jne	.L21
	movl	$0, -76(%rbp)
	jmp	.L22
.L23:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-64(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movb	$46, (%rax)
	addl	$1, -76(%rbp)
.L22:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L23
.L21:
	movl	-68(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-32(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %eax
	movl	-68(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	movq	-32(%rbp), %rdx
	addq	%rcx, %rdx
	movl	%eax, %ecx
	shrl	$31, %ecx
	addl	%ecx, %eax
	sarl	%eax
	movl	%eax, (%rdx)
	addl	$1, -64(%rbp)
.L20:
	movl	-84(%rbp), %eax
	cmpl	%eax, -64(%rbp)
	jl	.L24
	movl	$0, -60(%rbp)
	movl	$0, -76(%rbp)
	jmp	.L25
.L29:
	movl	$0, -72(%rbp)
	jmp	.L26
.L28:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rdx
	movl	-72(%rbp), %eax
	cltq
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	jne	.L27
	addl	$1, -60(%rbp)
.L27:
	addl	$1, -72(%rbp)
.L26:
	movl	-84(%rbp), %eax
	cmpl	%eax, -72(%rbp)
	jl	.L28
	addl	$1, -76(%rbp)
.L25:
	movl	-88(%rbp), %eax
	cmpl	%eax, -76(%rbp)
	jl	.L29
	movl	-80(%rbp), %eax
	cmpl	%eax, -60(%rbp)
	jne	.L30
	addl	$1, -56(%rbp)
.L30:
	addl	$1, -68(%rbp)
.L10:
	movl	-88(%rbp), %edx
	movl	-84(%rbp), %eax
	addl	%edx, %eax
	pxor	%xmm0, %xmm0
	cvtsi2sdl	%eax, %xmm0
	movq	.LC1(%rip), %rax
	movapd	%xmm0, %xmm1
	movq	%rax, %xmm0
	call	pow@PLT
	cvttsd2sil	%xmm0, %eax
	cmpl	%eax, -68(%rbp)
	jl	.L31
	movl	-56(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movq	-32(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movl	-88(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	.L32
.L33:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-40(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rdi
	call	free@PLT
	subl	$1, -76(%rbp)
.L32:
	cmpl	$0, -76(%rbp)
	jns	.L33
	movl	-88(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -76(%rbp)
	jmp	.L34
.L35:
	movl	-76(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	movq	-48(%rbp), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	movq	%rax, %rdi
	call	free@PLT
	subl	$1, -76(%rbp)
.L34:
	cmpl	$0, -76(%rbp)
	jns	.L35
	movq	-40(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movq	-48(%rbp), %rax
	movq	%rax, %rdi
	call	free@PLT
	movl	$0, %eax
	movq	-24(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L37
	call	__stack_chk_fail@PLT
.L37:
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC1:
	.long	0
	.long	1073741824
	.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:
