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>

// Util
#define MIN(x, y) ((x) < (y) ? (x) : (y))
//


// I/O
int get_uint() {
    int n = 0;
    int c = getchar_unlocked();
    if(c < 48 || 57 < c) return c;
    while(47 < c && c < 58) n = 10 * n + (c & 0xf), c = getchar_unlocked();
    return n;
}
void put_uint(int n) {
    if(!n) {
        putchar_unlocked('0');
        return;
    }
    char buf[11];
    int i = 0;
    while(n) buf[i++] = (char)(n % 10 + '0'), n /= 10;
    while(i--)putchar_unlocked(buf[i]);
}
//


// Solve
int mcm(int *first, const int N) {
    int dp[N][N];
    for(int i = 0; i < N; ++i)
        for(int j = 0; j < N; ++j) dp[i][j] = 1 << 28;
    for(int i = 0; i < N; ++i) dp[i][i] = 0;
    for(int l = 0; l < N; ++l)
        for(int i = 0; i < N - l; ++i) {
            int j = i + l;
            for(int k = i; k < j; ++k)
                dp[i][j] = MIN(dp[i][j], dp[i][k] + dp[k + 1][j] + first[i] * first[k + 1] * first[j + 1]);
        }
    return dp[0][N - 1];
}

int main(int argc, char **argv) {
    int n = get_uint();
    int m[n + 1];
    for(int i = 0; i < n; ++i) m[i] = get_uint(), m[i + 1] = get_uint();
    put_uint(mcm(m, n));
    putchar_unlocked('\n');
    return 0;
}

```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	get_uint
	.type	get_uint, @function
get_uint:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	movl	$0, -8(%rbp)
	call	getchar_unlocked@PLT
	movl	%eax, -4(%rbp)
	cmpl	$47, -4(%rbp)
	jle	.L2
	cmpl	$57, -4(%rbp)
	jle	.L5
.L2:
	movl	-4(%rbp), %eax
	jmp	.L4
.L7:
	movl	-8(%rbp), %edx
	movl	%edx, %eax
	sall	$2, %eax
	addl	%edx, %eax
	addl	%eax, %eax
	movl	%eax, %edx
	movl	-4(%rbp), %eax
	andl	$15, %eax
	addl	%edx, %eax
	movl	%eax, -8(%rbp)
	call	getchar_unlocked@PLT
	movl	%eax, -4(%rbp)
.L5:
	cmpl	$47, -4(%rbp)
	jle	.L6
	cmpl	$57, -4(%rbp)
	jle	.L7
.L6:
	movl	-8(%rbp), %eax
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	get_uint, .-get_uint
	.globl	put_uint
	.type	put_uint, @function
put_uint:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movl	%edi, -36(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	cmpl	$0, -36(%rbp)
	jne	.L9
	movl	$48, %edi
	call	putchar_unlocked@PLT
	jmp	.L8
.L9:
	movl	$0, -24(%rbp)
	jmp	.L11
.L12:
	movl	-36(%rbp), %edx
	movslq	%edx, %rax
	imulq	$1717986919, %rax, %rax
	shrq	$32, %rax
	sarl	$2, %eax
	movl	%edx, %esi
	sarl	$31, %esi
	subl	%esi, %eax
	movl	%eax, %ecx
	movl	%ecx, %eax
	sall	$2, %eax
	addl	%ecx, %eax
	addl	%eax, %eax
	movl	%edx, %ecx
	subl	%eax, %ecx
	movl	%ecx, %eax
	leal	48(%rax), %ecx
	movl	-24(%rbp), %eax
	leal	1(%rax), %edx
	movl	%edx, -24(%rbp)
	movl	%ecx, %edx
	cltq
	movb	%dl, -19(%rbp,%rax)
	movl	-36(%rbp), %eax
	movslq	%eax, %rdx
	imulq	$1717986919, %rdx, %rdx
	shrq	$32, %rdx
	sarl	$2, %edx
	sarl	$31, %eax
	movl	%eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, -36(%rbp)
.L11:
	cmpl	$0, -36(%rbp)
	jne	.L12
	jmp	.L13
.L14:
	movl	-24(%rbp), %eax
	cltq
	movzbl	-19(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, %edi
	call	putchar_unlocked@PLT
.L13:
	movl	-24(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -24(%rbp)
	testl	%eax, %eax
	jne	.L14
.L8:
	movq	-8(%rbp), %rax
	subq	%fs:40, %rax
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	put_uint, .-put_uint
	.globl	mcm
	.type	mcm, @function
mcm:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$88, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%rdi, -120(%rbp)
	movl	%esi, -124(%rbp)
	movq	%fs:40, %rcx
	movq	%rcx, -56(%rbp)
	xorl	%ecx, %ecx
	movq	%rsp, %rcx
	movq	%rcx, %rbx
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	subq	$1, %rcx
	movq	%rcx, -80(%rbp)
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	movq	%rcx, %r14
	movl	$0, %r15d
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	salq	$2, %rcx
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	subq	$1, %rsi
	movq	%rsi, -72(%rbp)
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	movq	%rsi, %r12
	movl	$0, %r13d
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	movq	%rsi, %rax
	movl	$0, %edx
	movq	%r13, %rdi
	imulq	%rax, %rdi
	movq	%rdx, %rsi
	imulq	%r12, %rsi
	addq	%rdi, %rsi
	mulq	%r12
	addq	%rdx, %rsi
	movq	%rsi, %rdx
	movl	-124(%rbp), %eax
	cltq
	movq	%rax, %r10
	movl	$0, %r11d
	movl	-124(%rbp), %eax
	cltq
	movq	%rax, %r8
	movl	$0, %r9d
	movq	%r11, %rdx
	imulq	%r8, %rdx
	movq	%r9, %rax
	imulq	%r10, %rax
	leaq	(%rdx,%rax), %rsi
	movq	%r10, %rax
	mulq	%r8
	addq	%rdx, %rsi
	movq	%rsi, %rdx
	movl	-124(%rbp), %eax
	movslq	%eax, %rdx
	movl	-124(%rbp), %eax
	cltq
	imulq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	movl	$16, %eax
	subq	$1, %rax
	addq	%rdx, %rax
	movl	$16, %edi
	movl	$0, %edx
	divq	%rdi
	imulq	$16, %rax, %rax
	movq	%rax, %rsi
	andq	$-4096, %rsi
	movq	%rsp, %rdx
	subq	%rsi, %rdx
.L17:
	cmpq	%rdx, %rsp
	je	.L18
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	jmp	.L17
.L18:
	movq	%rax, %rdx
	andl	$4095, %edx
	subq	%rdx, %rsp
	movq	%rax, %rdx
	andl	$4095, %edx
	testq	%rdx, %rdx
	je	.L19
	andl	$4095, %eax
	subq	$8, %rax
	addq	%rsp, %rax
	orq	$0, (%rax)
.L19:
	movq	%rsp, %rax
	addq	$3, %rax
	shrq	$2, %rax
	salq	$2, %rax
	movq	%rax, -64(%rbp)
	movl	$0, -108(%rbp)
	jmp	.L20
.L23:
	movl	$0, -104(%rbp)
	jmp	.L21
.L22:
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movq	-64(%rbp), %rax
	movl	-104(%rbp), %edx
	movslq	%edx, %rdi
	movl	-108(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	addq	%rdi, %rdx
	movl	$268435456, (%rax,%rdx,4)
	addl	$1, -104(%rbp)
.L21:
	movl	-104(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L22
	addl	$1, -108(%rbp)
.L20:
	movl	-108(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L23
	movl	$0, -100(%rbp)
	jmp	.L24
.L25:
	movq	%rcx, %rdx
	shrq	$2, %rdx
	movq	-64(%rbp), %rax
	leaq	1(%rdx), %rsi
	movl	-100(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	movl	$0, (%rax,%rdx,4)
	addl	$1, -100(%rbp)
.L24:
	movl	-100(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L25
	movl	$0, -96(%rbp)
	jmp	.L26
.L31:
	movl	$0, -92(%rbp)
	jmp	.L27
.L30:
	movl	-92(%rbp), %edx
	movl	-96(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -84(%rbp)
	movl	-92(%rbp), %eax
	movl	%eax, -88(%rbp)
	jmp	.L28
.L29:
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movq	-64(%rbp), %rax
	movl	-88(%rbp), %edx
	movslq	%edx, %rdi
	movl	-92(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	addq	%rdi, %rdx
	movl	(%rax,%rdx,4), %r8d
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movl	-88(%rbp), %eax
	leal	1(%rax), %edi
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %edx
	movslq	%edx, %r9
	movslq	%edi, %rdx
	imulq	%rsi, %rdx
	addq	%r9, %rdx
	movl	(%rax,%rdx,4), %eax
	leal	(%r8,%rax), %esi
	movl	-92(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-120(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %edx
	movl	-88(%rbp), %eax
	cltq
	addq	$1, %rax
	leaq	0(,%rax,4), %rdi
	movq	-120(%rbp), %rax
	addq	%rdi, %rax
	movl	(%rax), %eax
	imull	%eax, %edx
	movl	-84(%rbp), %eax
	cltq
	addq	$1, %rax
	leaq	0(,%rax,4), %rdi
	movq	-120(%rbp), %rax
	addq	%rdi, %rax
	movl	(%rax), %eax
	imull	%edx, %eax
	leal	(%rsi,%rax), %edx
	movq	%rcx, %rdi
	shrq	$2, %rdi
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %esi
	movslq	%esi, %r8
	movl	-92(%rbp), %esi
	movslq	%esi, %rsi
	imulq	%rdi, %rsi
	addq	%r8, %rsi
	movl	(%rax,%rsi,4), %eax
	movq	%rcx, %rdi
	shrq	$2, %rdi
	cmpl	%eax, %edx
	cmovg	%eax, %edx
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %esi
	movslq	%esi, %r8
	movl	-92(%rbp), %esi
	movslq	%esi, %rsi
	imulq	%rdi, %rsi
	addq	%r8, %rsi
	movl	%edx, (%rax,%rsi,4)
	addl	$1, -88(%rbp)
.L28:
	movl	-88(%rbp), %eax
	cmpl	-84(%rbp), %eax
	jl	.L29
	addl	$1, -92(%rbp)
.L27:
	movl	-124(%rbp), %eax
	subl	-96(%rbp), %eax
	cmpl	%eax, -92(%rbp)
	jl	.L30
	addl	$1, -96(%rbp)
.L26:
	movl	-96(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L31
	movl	-124(%rbp), %eax
	leal	-1(%rax), %edx
	movq	-64(%rbp), %rax
	movslq	%edx, %rdx
	movl	(%rax,%rdx,4), %eax
	movq	%rbx, %rsp
	movq	-56(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L33
	call	__stack_chk_fail@PLT
.L33:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	mcm, .-mcm
	.globl	main
	.type	main, @function
main:
.LFB3:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 12, -40
	.cfi_offset 3, -48
	movl	%edi, -68(%rbp)
	movq	%rsi, -80(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -40(%rbp)
	xorl	%eax, %eax
	movq	%rsp, %rax
	movq	%rax, %r12
	movl	$0, %eax
	call	get_uint
	movl	%eax, -60(%rbp)
	movl	-60(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rdx
	subq	$1, %rdx
	movq	%rdx, -56(%rbp)
	movslq	%eax, %rdx
	movq	%rdx, -96(%rbp)
	movq	$0, -88(%rbp)
	movslq	%eax, %rdx
	movq	%rdx, %r14
	movl	$0, %r15d
	cltq
	leaq	0(,%rax,4), %rdx
	movl	$16, %eax
	subq	$1, %rax
	addq	%rdx, %rax
	movl	$16, %esi
	movl	$0, %edx
	divq	%rsi
	imulq	$16, %rax, %rax
	movq	%rax, %rcx
	andq	$-4096, %rcx
	movq	%rsp, %rdx
	subq	%rcx, %rdx
.L35:
	cmpq	%rdx, %rsp
	je	.L36
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	jmp	.L35
.L36:
	movq	%rax, %rdx
	andl	$4095, %edx
	subq	%rdx, %rsp
	movq	%rax, %rdx
	andl	$4095, %edx
	testq	%rdx, %rdx
	je	.L37
	andl	$4095, %eax
	subq	$8, %rax
	addq	%rsp, %rax
	orq	$0, (%rax)
.L37:
	movq	%rsp, %rax
	addq	$3, %rax
	shrq	$2, %rax
	salq	$2, %rax
	movq	%rax, -48(%rbp)
	movl	$0, -64(%rbp)
	jmp	.L38
.L39:
	movl	$0, %eax
	call	get_uint
	movq	-48(%rbp), %rdx
	movl	-64(%rbp), %ecx
	movslq	%ecx, %rcx
	movl	%eax, (%rdx,%rcx,4)
	movl	-64(%rbp), %eax
	leal	1(%rax), %ebx
	movl	$0, %eax
	call	get_uint
	movq	-48(%rbp), %rdx
	movslq	%ebx, %rcx
	movl	%eax, (%rdx,%rcx,4)
	addl	$1, -64(%rbp)
.L38:
	movl	-64(%rbp), %eax
	cmpl	-60(%rbp), %eax
	jl	.L39
	movl	-60(%rbp), %edx
	movq	-48(%rbp), %rax
	movl	%edx, %esi
	movq	%rax, %rdi
	call	mcm
	movl	%eax, %edi
	call	put_uint
	movl	$10, %edi
	call	putchar_unlocked@PLT
	movl	$0, %eax
	movq	%r12, %rsp
	movq	-40(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L41
	call	__stack_chk_fail@PLT
.L41:
	leaq	-32(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
user
	.file	"temp.c"
	.text
	.p2align 4
	.globl	get_uint
	.type	get_uint, @function
get_uint:
.LFB23:
	.cfi_startproc
	endbr64
	movq	stdin(%rip), %rdi
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	movq	8(%rdi), %rax
	cmpq	16(%rdi), %rax
	jnb	.L13
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
.L3:
	leal	-48(%rax), %edx
	movl	%eax, %r12d
	cmpl	$9, %edx
	ja	.L1
	xorl	%r12d, %r12d
.L11:
	movq	stdin(%rip), %rdi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L5:
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	ja	.L1
.L7:
	andl	$15, %eax
	leal	(%r12,%r12,4), %edx
	leal	(%rax,%rdx,2), %r12d
	movq	8(%rdi), %rax
	cmpq	16(%rdi), %rax
	jb	.L5
	call	__uflow@PLT
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	jbe	.L11
.L1:
	movl	%r12d, %eax
	popq	%r12
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L13:
	.cfi_restore_state
	call	__uflow@PLT
	jmp	.L3
	.cfi_endproc
.LFE23:
	.size	get_uint, .-get_uint
	.p2align 4
	.globl	put_uint
	.type	put_uint, @function
put_uint:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	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	$40, %rsp
	.cfi_def_cfa_offset 80
	movq	stdout(%rip), %r8
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	movq	40(%r8), %rcx
	movq	48(%r8), %rsi
	testl	%edi, %edi
	je	.L84
	movslq	%edi, %rax
	movl	%edi, %edx
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edx
	sarq	$34, %rax
	subl	%edx, %eax
	leal	(%rax,%rax,4), %edx
	movl	%eax, %ebx
	addl	%edx, %edx
	subl	%edx, %edi
	leal	48(%rdi), %ebp
	movb	%bpl, 13(%rsp)
	testl	%eax, %eax
	je	.L19
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 14(%rsp)
	testl	%edx, %edx
	je	.L43
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 15(%rsp)
	testl	%eax, %eax
	je	.L44
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 16(%rsp)
	testl	%edx, %edx
	je	.L45
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 17(%rsp)
	testl	%eax, %eax
	je	.L46
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 18(%rsp)
	testl	%edx, %edx
	je	.L47
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 19(%rsp)
	testl	%eax, %eax
	je	.L48
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 20(%rsp)
	testl	%edx, %edx
	je	.L49
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 21(%rsp)
	testl	%eax, %eax
	je	.L50
	addl	$48, %eax
	movl	$9, %ebx
	movb	%al, 22(%rsp)
.L19:
	movslq	%ebx, %rax
	movzbl	13(%rsp,%rax), %eax
	cmpq	%rsi, %rcx
	jnb	.L20
	leaq	1(%rcx), %rdx
	movq	%rdx, 40(%r8)
	movb	%al, (%rcx)
.L21:
	leal	-1(%rbx), %r12d
	testl	%ebx, %ebx
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	%rax, 48(%rdi)
	jbe	.L23
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L24:
	leal	-2(%rbx), %r13d
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r13d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L25
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L26:
	leal	-3(%rbx), %r12d
	testl	%r13d, %r13d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L27
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L28:
	leal	-4(%rbx), %r13d
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r13d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L29
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L30:
	leal	-5(%rbx), %r12d
	testl	%r13d, %r13d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L31
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L32:
	leal	-6(%rbx), %r13d
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r13d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L33
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L34:
	leal	-7(%rbx), %r12d
	testl	%r13d, %r13d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L35
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L36:
	subl	$8, %ebx
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%ebx, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L37
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L38:
	testl	%ebx, %ebx
	je	.L14
	movq	stdout(%rip), %rdi
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L39
	leaq	1(%rax), %rdx
	movq	%rdx, 40(%rdi)
	movb	%bpl, (%rax)
.L14:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L83
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	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
	.p2align 4,,10
	.p2align 3
.L84:
	.cfi_restore_state
	cmpq	%rsi, %rcx
	jnb	.L85
	leaq	1(%rcx), %rax
	movq	%rax, 40(%r8)
	movb	$48, (%rcx)
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L44:
	movl	$2, %ebx
	jmp	.L19
.L25:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L26
	.p2align 4,,10
	.p2align 3
.L43:
	movl	$1, %ebx
	jmp	.L19
	.p2align 4,,10
	.p2align 3
.L20:
	movzbl	%al, %esi
	movq	%r8, %rdi
	call	__overflow@PLT
	jmp	.L21
.L23:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L24
.L45:
	movl	$3, %ebx
	jmp	.L19
.L46:
	movl	$4, %ebx
	jmp	.L19
.L27:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L28
.L47:
	movl	$5, %ebx
	jmp	.L19
.L29:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L30
.L48:
	movl	$6, %ebx
	jmp	.L19
.L31:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L32
.L85:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L83
	movl	$48, %esi
	movq	%r8, %rdi
.L82:
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	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
	jmp	__overflow@PLT
.L33:
	.cfi_restore_state
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L34
.L49:
	movl	$7, %ebx
	jmp	.L19
.L35:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L36
.L50:
	movl	$8, %ebx
	jmp	.L19
.L37:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L38
.L39:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L83
	movzbl	%bpl, %esi
	jmp	.L82
.L83:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	put_uint, .-put_uint
	.p2align 4
	.globl	mcm
	.type	mcm, @function
mcm:
.LFB25:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movl	%esi, %edx
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	movq	%rdi, %r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$72, %rsp
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%fs:40, %rax
	movq	%rax, -56(%rbp)
	xorl	%eax, %eax
	movslq	%esi, %rax
	movq	%rsp, %rsi
	leaq	0(,%rax,4), %rbx
	imulq	%rax, %rax
	movq	%rbx, -96(%rbp)
	leaq	15(,%rax,4), %rcx
	movq	%rcx, %rax
	andq	$-4096, %rcx
	subq	%rcx, %rsi
	andq	$-16, %rax
	cmpq	%rsi, %rsp
	je	.L88
.L119:
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	cmpq	%rsi, %rsp
	jne	.L119
.L88:
	andl	$4095, %eax
	subq	%rax, %rsp
	testq	%rax, %rax
	jne	.L120
.L89:
	movq	-96(%rbp), %r13
	movq	%rsp, %r15
	shrq	$2, %r13
	testl	%edx, %edx
	jle	.L121
	movl	%edx, %eax
	leal	-1(%rdx), %r10d
	movl	%edx, %edi
	movdqa	.LC0(%rip), %xmm0
	shrl	$2, %eax
	movl	%r10d, -108(%rbp)
	movq	-96(%rbp), %r9
	andl	$-4, %edi
	leal	-1(%rax), %r8d
	movq	%r15, %rcx
	xorl	%esi, %esi
	addq	$1, %r8
	salq	$4, %r8
	cmpl	$2, %r10d
	jbe	.L105
	.p2align 4,,10
	.p2align 3
.L122:
	leaq	(%r8,%rcx), %r11
	movq	%rcx, %rax
	.p2align 4,,10
	.p2align 3
.L93:
	movups	%xmm0, (%rax)
	addq	$16, %rax
	cmpq	%r11, %rax
	jne	.L93
	movl	%edi, %eax
	cmpl	%edx, %edi
	je	.L92
.L96:
	movslq	%esi, %r11
	movslq	%eax, %rbx
	imulq	%r13, %r11
	addq	%r11, %rbx
	movl	$268435456, (%r15,%rbx,4)
	leal	1(%rax), %ebx
	cmpl	%ebx, %edx
	jle	.L92
	movslq	%ebx, %rbx
	addl	$2, %eax
	addq	%r11, %rbx
	movl	$268435456, (%r15,%rbx,4)
	cmpl	%eax, %edx
	jle	.L92
	cltq
	addq	%r11, %rax
	movl	$268435456, (%r15,%rax,4)
.L92:
	leal	1(%rsi), %eax
	addq	%r9, %rcx
	cmpl	%eax, %edx
	je	.L104
	movl	%eax, %esi
	cmpl	$2, %r10d
	ja	.L122
.L105:
	xorl	%eax, %eax
	jmp	.L96
.L104:
	xorl	%eax, %eax
	leaq	1(%r13), %rdi
	.p2align 4,,10
	.p2align 3
.L95:
	movslq	%eax, %rcx
	imulq	%rdi, %rcx
	movl	$0, (%r15,%rcx,4)
	movl	%eax, %ecx
	addl	$1, %eax
	cmpl	%ecx, %esi
	jne	.L95
	leal	-2(%rdx), %eax
	movq	%r14, -104(%rbp)
	movl	$-1, -72(%rbp)
	movl	%eax, -112(%rbp)
	.p2align 4,,10
	.p2align 3
.L97:
	movl	-72(%rbp), %ebx
	movl	-112(%rbp), %edi
	xorl	%r12d, %r12d
	movq	%r15, %r10
	movl	%ebx, %r9d
	addl	$1, %ebx
	movq	%r9, %rax
	movl	%ebx, -72(%rbp)
	addq	$2, %r9
	subl	%eax, %edi
	movl	%ebx, -68(%rbp)
	movq	%rdi, -88(%rbp)
	movslq	%r12d, %rdi
	cmpl	%r12d, -68(%rbp)
	jle	.L123
	.p2align 4,,10
	.p2align 3
.L98:
	movq	-104(%rbp), %rax
	movslq	-68(%rbp), %r8
	imulq	%r13, %rdi
	movl	(%r14,%r12,4), %ebx
	movl	4(%rax,%r12,4), %r11d
	movslq	%r12d, %rax
	imulq	%r13, %rax
	addq	%r8, %rdi
	addq	%r8, %rax
	movl	(%r15,%rax,4), %ecx
	leaq	1(%r12), %rax
	movq	%rax, -80(%rbp)
	movq	%rax, %rdx
	.p2align 4,,10
	.p2align 3
.L101:
	movl	(%r14,%rdx,4), %esi
	movslq	%edx, %rax
	imulq	%r13, %rax
	imull	%ebx, %esi
	addq	%r8, %rax
	imull	%r11d, %esi
	movl	(%r15,%rax,4), %eax
	addl	-4(%r10,%rdx,4), %eax
	addl	%esi, %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	addq	$1, %rdx
	movl	%ecx, (%r15,%rdi,4)
	cmpq	%r9, %rdx
	jne	.L101
.L102:
	addl	$1, -68(%rbp)
	addq	-96(%rbp), %r10
	addq	$1, %r9
	cmpq	-88(%rbp), %r12
	je	.L124
	movq	-80(%rbp), %r12
	movslq	%r12d, %rdi
	cmpl	%r12d, -68(%rbp)
	jg	.L98
.L123:
	leaq	1(%r12), %rax
	movq	%rax, -80(%rbp)
	jmp	.L102
	.p2align 4,,10
	.p2align 3
.L124:
	addq	$4, -104(%rbp)
	movl	-72(%rbp), %ebx
	cmpl	%ebx, -108(%rbp)
	jne	.L97
.L90:
	movslq	-108(%rbp), %rax
	movl	(%r15,%rax,4), %eax
	movq	-56(%rbp), %rdx
	subq	%fs:40, %rdx
	jne	.L125
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
.L120:
	.cfi_restore_state
	orq	$0, -8(%rsp,%rax)
	jmp	.L89
.L121:
	leal	-1(%rdx), %eax
	movl	%eax, -108(%rbp)
	jmp	.L90
.L125:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	mcm, .-mcm
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB26:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%fs:40, %rax
	movq	%rax, -56(%rbp)
	xorl	%eax, %eax
	call	get_uint
	movq	%rsp, %rcx
	movl	%eax, %r12d
	leal	1(%rax), %eax
	cltq
	leaq	15(,%rax,4), %rax
	movq	%rax, %rdx
	andq	$-4096, %rax
	subq	%rax, %rcx
	andq	$-16, %rdx
	cmpq	%rcx, %rsp
	je	.L128
.L159:
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	cmpq	%rcx, %rsp
	jne	.L159
.L128:
	andl	$4095, %edx
	subq	%rdx, %rsp
	testq	%rdx, %rdx
	jne	.L160
.L129:
	movq	%rsp, %r13
	testl	%r12d, %r12d
	jle	.L146
	leal	-1(%r12), %eax
	movq	%r13, %r14
	leaq	4(%r13,%rax,4), %rbx
	.p2align 4,,10
	.p2align 3
.L145:
	movq	stdin(%rip), %rdi
	movq	8(%rdi), %rax
	movq	16(%rdi), %rsi
	cmpq	%rsi, %rax
	jnb	.L161
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
.L134:
	leal	-48(%rax), %ecx
	cmpl	$9, %ecx
	ja	.L149
	xorl	%r15d, %r15d
	jmp	.L138
	.p2align 4,,10
	.p2align 3
.L136:
	leaq	1(%rdx), %rcx
	movq	%rcx, 8(%rdi)
	movzbl	(%rdx), %eax
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	ja	.L135
.L137:
	movq	%rcx, %rdx
.L138:
	leal	(%r15,%r15,4), %ecx
	andl	$15, %eax
	leal	(%rax,%rcx,2), %r15d
	cmpq	%rsi, %rdx
	jb	.L136
	call	__uflow@PLT
	movq	stdin(%rip), %rdi
	leal	-48(%rax), %edx
	movq	8(%rdi), %rcx
	movq	16(%rdi), %rsi
	cmpl	$9, %edx
	jbe	.L137
	.p2align 4,,10
	.p2align 3
.L135:
	movl	%r15d, (%r14)
	cmpq	%rsi, %rcx
	jnb	.L162
.L139:
	leaq	1(%rcx), %rax
	movq	%rax, 8(%rdi)
	movzbl	(%rcx), %eax
.L140:
	leal	-48(%rax), %edx
	movl	%eax, %r15d
	cmpl	$9, %edx
	ja	.L141
	xorl	%r15d, %r15d
.L158:
	movq	stdin(%rip), %rdi
	jmp	.L144
	.p2align 4,,10
	.p2align 3
.L142:
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	ja	.L141
.L144:
	andl	$15, %eax
	leal	(%r15,%r15,4), %edx
	leal	(%rax,%rdx,2), %r15d
	movq	8(%rdi), %rax
	cmpq	16(%rdi), %rax
	jb	.L142
	call	__uflow@PLT
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	jbe	.L158
	.p2align 4,,10
	.p2align 3
.L141:
	movl	%r15d, 4(%r14)
	addq	$4, %r14
	cmpq	%r14, %rbx
	jne	.L145
.L146:
	movl	%r12d, %esi
	movq	%r13, %rdi
	call	mcm
	movl	%eax, %edi
	call	put_uint
	movq	stdout(%rip), %rdi
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L163
	leaq	1(%rax), %rdx
	movq	%rdx, 40(%rdi)
	movb	$10, (%rax)
.L147:
	movq	-56(%rbp), %rax
	subq	%fs:40, %rax
	jne	.L164
	leaq	-40(%rbp), %rsp
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
	.p2align 4,,10
	.p2align 3
.L149:
	.cfi_restore_state
	movl	%eax, %r15d
	movq	%rdx, %rcx
	movl	%r15d, (%r14)
	cmpq	%rsi, %rcx
	jb	.L139
.L162:
	call	__uflow@PLT
	jmp	.L140
	.p2align 4,,10
	.p2align 3
.L161:
	call	__uflow@PLT
	movq	stdin(%rip), %rdi
	movq	8(%rdi), %rdx
	movq	16(%rdi), %rsi
	jmp	.L134
.L160:
	orq	$0, -8(%rsp,%rdx)
	jmp	.L129
.L163:
	movl	$10, %esi
	call	__overflow@PLT
	jmp	.L147
.L164:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE26:
	.size	main, .-main
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.long	268435456
	.long	268435456
	.long	268435456
	.long	268435456
	.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
	.p2align 4
	.globl	get_uint
	.type	get_uint, @function
get_uint:
.LFB23:
	.cfi_startproc
	endbr64
	movq	stdin(%rip), %rdi
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	movq	8(%rdi), %rax
	cmpq	16(%rdi), %rax
	jnb	.L13
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
.L3:
	leal	-48(%rax), %edx
	movl	%eax, %r12d
	cmpl	$9, %edx
	ja	.L1
	xorl	%r12d, %r12d
.L11:
	movq	stdin(%rip), %rdi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L5:
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	ja	.L1
.L7:
	andl	$15, %eax
	leal	(%r12,%r12,4), %edx
	leal	(%rax,%rdx,2), %r12d
	movq	8(%rdi), %rax
	cmpq	16(%rdi), %rax
	jb	.L5
	call	__uflow@PLT
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	jbe	.L11
.L1:
	movl	%r12d, %eax
	popq	%r12
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L13:
	.cfi_restore_state
	call	__uflow@PLT
	jmp	.L3
	.cfi_endproc
.LFE23:
	.size	get_uint, .-get_uint
	.p2align 4
	.globl	put_uint
	.type	put_uint, @function
put_uint:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	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	$40, %rsp
	.cfi_def_cfa_offset 80
	movq	stdout(%rip), %r8
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	movq	40(%r8), %rcx
	movq	48(%r8), %rsi
	testl	%edi, %edi
	je	.L84
	movslq	%edi, %rax
	movl	%edi, %edx
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edx
	sarq	$34, %rax
	subl	%edx, %eax
	leal	(%rax,%rax,4), %edx
	movl	%eax, %ebx
	addl	%edx, %edx
	subl	%edx, %edi
	leal	48(%rdi), %ebp
	movb	%bpl, 13(%rsp)
	testl	%eax, %eax
	je	.L19
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 14(%rsp)
	testl	%edx, %edx
	je	.L43
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 15(%rsp)
	testl	%eax, %eax
	je	.L44
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 16(%rsp)
	testl	%edx, %edx
	je	.L45
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 17(%rsp)
	testl	%eax, %eax
	je	.L46
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 18(%rsp)
	testl	%edx, %edx
	je	.L47
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 19(%rsp)
	testl	%eax, %eax
	je	.L48
	movslq	%eax, %rdx
	movl	%eax, %edi
	imulq	$1717986919, %rdx, %rdx
	sarl	$31, %edi
	sarq	$34, %rdx
	subl	%edi, %edx
	leal	(%rdx,%rdx,4), %edi
	addl	%edi, %edi
	subl	%edi, %eax
	addl	$48, %eax
	movb	%al, 20(%rsp)
	testl	%edx, %edx
	je	.L49
	movslq	%edx, %rax
	movl	%edx, %edi
	imulq	$1717986919, %rax, %rax
	sarl	$31, %edi
	sarq	$34, %rax
	subl	%edi, %eax
	leal	(%rax,%rax,4), %edi
	addl	%edi, %edi
	subl	%edi, %edx
	addl	$48, %edx
	movb	%dl, 21(%rsp)
	testl	%eax, %eax
	je	.L50
	addl	$48, %eax
	movl	$9, %ebx
	movb	%al, 22(%rsp)
.L19:
	movslq	%ebx, %rax
	movzbl	13(%rsp,%rax), %eax
	cmpq	%rsi, %rcx
	jnb	.L20
	leaq	1(%rcx), %rdx
	movq	%rdx, 40(%r8)
	movb	%al, (%rcx)
.L21:
	leal	-1(%rbx), %r12d
	testl	%ebx, %ebx
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	%rax, 48(%rdi)
	jbe	.L23
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L24:
	leal	-2(%rbx), %r13d
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r13d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L25
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L26:
	leal	-3(%rbx), %r12d
	testl	%r13d, %r13d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L27
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L28:
	leal	-4(%rbx), %r13d
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r13d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L29
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L30:
	leal	-5(%rbx), %r12d
	testl	%r13d, %r13d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L31
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L32:
	leal	-6(%rbx), %r13d
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r13d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L33
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L34:
	leal	-7(%rbx), %r12d
	testl	%r13d, %r13d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%r12d, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L35
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L36:
	subl	$8, %ebx
	testl	%r12d, %r12d
	je	.L14
	movq	stdout(%rip), %rdi
	movslq	%ebx, %rax
	movzbl	13(%rsp,%rax), %edx
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L37
	leaq	1(%rax), %rcx
	movq	%rcx, 40(%rdi)
	movb	%dl, (%rax)
.L38:
	testl	%ebx, %ebx
	je	.L14
	movq	stdout(%rip), %rdi
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L39
	leaq	1(%rax), %rdx
	movq	%rdx, 40(%rdi)
	movb	%bpl, (%rax)
.L14:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L83
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	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
	.p2align 4,,10
	.p2align 3
.L84:
	.cfi_restore_state
	cmpq	%rsi, %rcx
	jnb	.L85
	leaq	1(%rcx), %rax
	movq	%rax, 40(%r8)
	movb	$48, (%rcx)
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L44:
	movl	$2, %ebx
	jmp	.L19
.L25:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L26
	.p2align 4,,10
	.p2align 3
.L43:
	movl	$1, %ebx
	jmp	.L19
	.p2align 4,,10
	.p2align 3
.L20:
	movzbl	%al, %esi
	movq	%r8, %rdi
	call	__overflow@PLT
	jmp	.L21
.L23:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L24
.L45:
	movl	$3, %ebx
	jmp	.L19
.L46:
	movl	$4, %ebx
	jmp	.L19
.L27:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L28
.L47:
	movl	$5, %ebx
	jmp	.L19
.L29:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L30
.L48:
	movl	$6, %ebx
	jmp	.L19
.L31:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L32
.L85:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L83
	movl	$48, %esi
	movq	%r8, %rdi
.L82:
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	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
	jmp	__overflow@PLT
.L33:
	.cfi_restore_state
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L34
.L49:
	movl	$7, %ebx
	jmp	.L19
.L35:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L36
.L50:
	movl	$8, %ebx
	jmp	.L19
.L37:
	movzbl	%dl, %esi
	call	__overflow@PLT
	jmp	.L38
.L39:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L83
	movzbl	%bpl, %esi
	jmp	.L82
.L83:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	put_uint, .-put_uint
	.p2align 4
	.globl	mcm
	.type	mcm, @function
mcm:
.LFB25:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movl	%esi, %edx
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	movq	%rdi, %r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$72, %rsp
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%fs:40, %rax
	movq	%rax, -56(%rbp)
	xorl	%eax, %eax
	movslq	%esi, %rax
	movq	%rsp, %rsi
	leaq	0(,%rax,4), %rbx
	imulq	%rax, %rax
	movq	%rbx, -96(%rbp)
	leaq	15(,%rax,4), %rcx
	movq	%rcx, %rax
	andq	$-4096, %rcx
	subq	%rcx, %rsi
	andq	$-16, %rax
	cmpq	%rsi, %rsp
	je	.L88
.L119:
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	cmpq	%rsi, %rsp
	jne	.L119
.L88:
	andl	$4095, %eax
	subq	%rax, %rsp
	testq	%rax, %rax
	jne	.L120
.L89:
	movq	-96(%rbp), %r13
	movq	%rsp, %r15
	shrq	$2, %r13
	testl	%edx, %edx
	jle	.L121
	movl	%edx, %eax
	leal	-1(%rdx), %r10d
	movl	%edx, %edi
	movdqa	.LC0(%rip), %xmm0
	shrl	$2, %eax
	movl	%r10d, -108(%rbp)
	movq	-96(%rbp), %r9
	andl	$-4, %edi
	leal	-1(%rax), %r8d
	movq	%r15, %rcx
	xorl	%esi, %esi
	addq	$1, %r8
	salq	$4, %r8
	cmpl	$2, %r10d
	jbe	.L105
	.p2align 4,,10
	.p2align 3
.L122:
	leaq	(%r8,%rcx), %r11
	movq	%rcx, %rax
	.p2align 4,,10
	.p2align 3
.L93:
	movups	%xmm0, (%rax)
	addq	$16, %rax
	cmpq	%r11, %rax
	jne	.L93
	movl	%edi, %eax
	cmpl	%edx, %edi
	je	.L92
.L96:
	movslq	%esi, %r11
	movslq	%eax, %rbx
	imulq	%r13, %r11
	addq	%r11, %rbx
	movl	$268435456, (%r15,%rbx,4)
	leal	1(%rax), %ebx
	cmpl	%ebx, %edx
	jle	.L92
	movslq	%ebx, %rbx
	addl	$2, %eax
	addq	%r11, %rbx
	movl	$268435456, (%r15,%rbx,4)
	cmpl	%eax, %edx
	jle	.L92
	cltq
	addq	%r11, %rax
	movl	$268435456, (%r15,%rax,4)
.L92:
	leal	1(%rsi), %eax
	addq	%r9, %rcx
	cmpl	%eax, %edx
	je	.L104
	movl	%eax, %esi
	cmpl	$2, %r10d
	ja	.L122
.L105:
	xorl	%eax, %eax
	jmp	.L96
.L104:
	xorl	%eax, %eax
	leaq	1(%r13), %rdi
	.p2align 4,,10
	.p2align 3
.L95:
	movslq	%eax, %rcx
	imulq	%rdi, %rcx
	movl	$0, (%r15,%rcx,4)
	movl	%eax, %ecx
	addl	$1, %eax
	cmpl	%ecx, %esi
	jne	.L95
	leal	-2(%rdx), %eax
	movq	%r14, -104(%rbp)
	movl	$-1, -72(%rbp)
	movl	%eax, -112(%rbp)
	.p2align 4,,10
	.p2align 3
.L97:
	movl	-72(%rbp), %ebx
	movl	-112(%rbp), %edi
	xorl	%r12d, %r12d
	movq	%r15, %r10
	movl	%ebx, %r9d
	addl	$1, %ebx
	movq	%r9, %rax
	movl	%ebx, -72(%rbp)
	addq	$2, %r9
	subl	%eax, %edi
	movl	%ebx, -68(%rbp)
	movq	%rdi, -88(%rbp)
	movslq	%r12d, %rdi
	cmpl	%r12d, -68(%rbp)
	jle	.L123
	.p2align 4,,10
	.p2align 3
.L98:
	movq	-104(%rbp), %rax
	movslq	-68(%rbp), %r8
	imulq	%r13, %rdi
	movl	(%r14,%r12,4), %ebx
	movl	4(%rax,%r12,4), %r11d
	movslq	%r12d, %rax
	imulq	%r13, %rax
	addq	%r8, %rdi
	addq	%r8, %rax
	movl	(%r15,%rax,4), %ecx
	leaq	1(%r12), %rax
	movq	%rax, -80(%rbp)
	movq	%rax, %rdx
	.p2align 4,,10
	.p2align 3
.L101:
	movl	(%r14,%rdx,4), %esi
	movslq	%edx, %rax
	imulq	%r13, %rax
	imull	%ebx, %esi
	addq	%r8, %rax
	imull	%r11d, %esi
	movl	(%r15,%rax,4), %eax
	addl	-4(%r10,%rdx,4), %eax
	addl	%esi, %eax
	cmpl	%eax, %ecx
	cmovg	%eax, %ecx
	addq	$1, %rdx
	movl	%ecx, (%r15,%rdi,4)
	cmpq	%r9, %rdx
	jne	.L101
.L102:
	addl	$1, -68(%rbp)
	addq	-96(%rbp), %r10
	addq	$1, %r9
	cmpq	-88(%rbp), %r12
	je	.L124
	movq	-80(%rbp), %r12
	movslq	%r12d, %rdi
	cmpl	%r12d, -68(%rbp)
	jg	.L98
.L123:
	leaq	1(%r12), %rax
	movq	%rax, -80(%rbp)
	jmp	.L102
	.p2align 4,,10
	.p2align 3
.L124:
	addq	$4, -104(%rbp)
	movl	-72(%rbp), %ebx
	cmpl	%ebx, -108(%rbp)
	jne	.L97
.L90:
	movslq	-108(%rbp), %rax
	movl	(%r15,%rax,4), %eax
	movq	-56(%rbp), %rdx
	subq	%fs:40, %rdx
	jne	.L125
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
.L120:
	.cfi_restore_state
	orq	$0, -8(%rsp,%rax)
	jmp	.L89
.L121:
	leal	-1(%rdx), %eax
	movl	%eax, -108(%rbp)
	jmp	.L90
.L125:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	mcm, .-mcm
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB26:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%fs:40, %rax
	movq	%rax, -56(%rbp)
	xorl	%eax, %eax
	call	get_uint
	movq	%rsp, %rcx
	movl	%eax, %r12d
	leal	1(%rax), %eax
	cltq
	leaq	15(,%rax,4), %rax
	movq	%rax, %rdx
	andq	$-4096, %rax
	subq	%rax, %rcx
	andq	$-16, %rdx
	cmpq	%rcx, %rsp
	je	.L128
.L159:
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	cmpq	%rcx, %rsp
	jne	.L159
.L128:
	andl	$4095, %edx
	subq	%rdx, %rsp
	testq	%rdx, %rdx
	jne	.L160
.L129:
	movq	%rsp, %r13
	testl	%r12d, %r12d
	jle	.L146
	leal	-1(%r12), %eax
	movq	%r13, %r14
	leaq	4(%r13,%rax,4), %rbx
	.p2align 4,,10
	.p2align 3
.L145:
	movq	stdin(%rip), %rdi
	movq	8(%rdi), %rax
	movq	16(%rdi), %rsi
	cmpq	%rsi, %rax
	jnb	.L161
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
.L134:
	leal	-48(%rax), %ecx
	cmpl	$9, %ecx
	ja	.L149
	xorl	%r15d, %r15d
	jmp	.L138
	.p2align 4,,10
	.p2align 3
.L136:
	leaq	1(%rdx), %rcx
	movq	%rcx, 8(%rdi)
	movzbl	(%rdx), %eax
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	ja	.L135
.L137:
	movq	%rcx, %rdx
.L138:
	leal	(%r15,%r15,4), %ecx
	andl	$15, %eax
	leal	(%rax,%rcx,2), %r15d
	cmpq	%rsi, %rdx
	jb	.L136
	call	__uflow@PLT
	movq	stdin(%rip), %rdi
	leal	-48(%rax), %edx
	movq	8(%rdi), %rcx
	movq	16(%rdi), %rsi
	cmpl	$9, %edx
	jbe	.L137
	.p2align 4,,10
	.p2align 3
.L135:
	movl	%r15d, (%r14)
	cmpq	%rsi, %rcx
	jnb	.L162
.L139:
	leaq	1(%rcx), %rax
	movq	%rax, 8(%rdi)
	movzbl	(%rcx), %eax
.L140:
	leal	-48(%rax), %edx
	movl	%eax, %r15d
	cmpl	$9, %edx
	ja	.L141
	xorl	%r15d, %r15d
.L158:
	movq	stdin(%rip), %rdi
	jmp	.L144
	.p2align 4,,10
	.p2align 3
.L142:
	leaq	1(%rax), %rdx
	movq	%rdx, 8(%rdi)
	movzbl	(%rax), %eax
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	ja	.L141
.L144:
	andl	$15, %eax
	leal	(%r15,%r15,4), %edx
	leal	(%rax,%rdx,2), %r15d
	movq	8(%rdi), %rax
	cmpq	16(%rdi), %rax
	jb	.L142
	call	__uflow@PLT
	leal	-48(%rax), %edx
	cmpl	$9, %edx
	jbe	.L158
	.p2align 4,,10
	.p2align 3
.L141:
	movl	%r15d, 4(%r14)
	addq	$4, %r14
	cmpq	%r14, %rbx
	jne	.L145
.L146:
	movl	%r12d, %esi
	movq	%r13, %rdi
	call	mcm
	movl	%eax, %edi
	call	put_uint
	movq	stdout(%rip), %rdi
	movq	40(%rdi), %rax
	cmpq	48(%rdi), %rax
	jnb	.L163
	leaq	1(%rax), %rdx
	movq	%rdx, 40(%rdi)
	movb	$10, (%rax)
.L147:
	movq	-56(%rbp), %rax
	subq	%fs:40, %rax
	jne	.L164
	leaq	-40(%rbp), %rsp
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
	.p2align 4,,10
	.p2align 3
.L149:
	.cfi_restore_state
	movl	%eax, %r15d
	movq	%rdx, %rcx
	movl	%r15d, (%r14)
	cmpq	%rsi, %rcx
	jb	.L139
.L162:
	call	__uflow@PLT
	jmp	.L140
	.p2align 4,,10
	.p2align 3
.L161:
	call	__uflow@PLT
	movq	stdin(%rip), %rdi
	movq	8(%rdi), %rdx
	movq	16(%rdi), %rsi
	jmp	.L134
.L160:
	orq	$0, -8(%rsp,%rdx)
	jmp	.L129
.L163:
	movl	$10, %esi
	call	__overflow@PLT
	jmp	.L147
.L164:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE26:
	.size	main, .-main
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.long	268435456
	.long	268435456
	.long	268435456
	.long	268435456
	.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>

// Util
#define MIN(x, y) ((x) < (y) ? (x) : (y))
//


// I/O
int get_uint() {
    int n = 0;
    int c = getchar_unlocked();
    if(c < 48 || 57 < c) return c;
    while(47 < c && c < 58) n = 10 * n + (c & 0xf), c = getchar_unlocked();
    return n;
}
void put_uint(int n) {
    if(!n) {
        putchar_unlocked('0');
        return;
    }
    char buf[11];
    int i = 0;
    while(n) buf[i++] = (char)(n % 10 + '0'), n /= 10;
    while(i--)putchar_unlocked(buf[i]);
}
//


// Solve
int mcm(int *first, const int N) {
    int dp[N][N];
    for(int i = 0; i < N; ++i)
        for(int j = 0; j < N; ++j) dp[i][j] = 1 << 28;
    for(int i = 0; i < N; ++i) dp[i][i] = 0;
    for(int l = 0; l < N; ++l)
        for(int i = 0; i < N - l; ++i) {
            int j = i + l;
            for(int k = i; k < j; ++k)
                dp[i][j] = MIN(dp[i][j], dp[i][k] + dp[k + 1][j] + first[i] * first[k + 1] * first[j + 1]);
        }
    return dp[0][N - 1];
}

int main(int argc, char **argv) {
    int n = get_uint();
    int m[n + 1];
    for(int i = 0; i < n; ++i) m[i] = get_uint(), m[i + 1] = get_uint();
    put_uint(mcm(m, n));
    putchar_unlocked('\n');
    return 0;
}


6
10 35
35 15
15 5
5 10
10 20
20 25
 6
1 35
35 15
15 5
5 10
10 20
20 25
 6
30 35
35 15
15 5
5 10
10 20
20 29
 6
2 35
35 15
15 5
5 10
10 20
20 25
 6
2 35
35 15
15 5
5 10
10 20
20 24
 6
30 35
35 15
15 5
5 10
10 20
20 27
 6
30 35
35 15
15 5
5 10
10 20
20 8
 6
30 35
35 15
15 5
5 10
10 20
20 7
 6
2 35
35 15
15 5
5 10
10 20
20 34
 6
29 35
35 15
15 5
5 10
10 20
20 7

9125
 1350
 16125
 2700
 2660
 15625
 10875
 10625
 3060
 10415

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>

// Util
#define MIN(x, y) ((x) < (y) ? (x) : (y))
//


// I/O
int get_uint() {
    int n = 0;
    int c = getchar_unlocked();
    if(c < 48 || 57 < c) return c;
    while(47 < c && c < 58) n = 10 * n + (c & 0xf), c = getchar_unlocked();
    return n;
}
void put_uint(int n) {
    if(!n) {
        putchar_unlocked('0');
        return;
    }
    char buf[11];
    int i = 0;
    while(n) buf[i++] = (char)(n % 10 + '0'), n /= 10;
    while(i--)putchar_unlocked(buf[i]);
}
//


// Solve
int mcm(int *first, const int N) {
    int dp[N][N];
    for(int i = 0; i < N; ++i)
        for(int j = 0; j < N; ++j) dp[i][j] = 1 << 28;
    for(int i = 0; i < N; ++i) dp[i][i] = 0;
    for(int l = 0; l < N; ++l)
        for(int i = 0; i < N - l; ++i) {
            int j = i + l;
            for(int k = i; k < j; ++k)
                dp[i][j] = MIN(dp[i][j], dp[i][k] + dp[k + 1][j] + first[i] * first[k + 1] * first[j + 1]);
        }
    return dp[0][N - 1];
}

int main(int argc, char **argv) {
    int n = get_uint();
    int m[n + 1];
    for(int i = 0; i < n; ++i) m[i] = get_uint(), m[i + 1] = get_uint();
    put_uint(mcm(m, n));
    putchar_unlocked('\n');
    return 0;
}

```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	get_uint
	.type	get_uint, @function
get_uint:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	movl	$0, -8(%rbp)
	call	getchar_unlocked@PLT
	movl	%eax, -4(%rbp)
	cmpl	$47, -4(%rbp)
	jle	.L2
	cmpl	$57, -4(%rbp)
	jle	.L5
.L2:
	movl	-4(%rbp), %eax
	jmp	.L4
.L7:
	movl	-8(%rbp), %edx
	movl	%edx, %eax
	sall	$2, %eax
	addl	%edx, %eax
	addl	%eax, %eax
	movl	%eax, %edx
	movl	-4(%rbp), %eax
	andl	$15, %eax
	addl	%edx, %eax
	movl	%eax, -8(%rbp)
	call	getchar_unlocked@PLT
	movl	%eax, -4(%rbp)
.L5:
	cmpl	$47, -4(%rbp)
	jle	.L6
	cmpl	$57, -4(%rbp)
	jle	.L7
.L6:
	movl	-8(%rbp), %eax
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	get_uint, .-get_uint
	.globl	put_uint
	.type	put_uint, @function
put_uint:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movl	%edi, -36(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	cmpl	$0, -36(%rbp)
	jne	.L9
	movl	$48, %edi
	call	putchar_unlocked@PLT
	jmp	.L8
.L9:
	movl	$0, -24(%rbp)
	jmp	.L11
.L12:
	movl	-36(%rbp), %edx
	movslq	%edx, %rax
	imulq	$1717986919, %rax, %rax
	shrq	$32, %rax
	sarl	$2, %eax
	movl	%edx, %esi
	sarl	$31, %esi
	subl	%esi, %eax
	movl	%eax, %ecx
	movl	%ecx, %eax
	sall	$2, %eax
	addl	%ecx, %eax
	addl	%eax, %eax
	movl	%edx, %ecx
	subl	%eax, %ecx
	movl	%ecx, %eax
	leal	48(%rax), %ecx
	movl	-24(%rbp), %eax
	leal	1(%rax), %edx
	movl	%edx, -24(%rbp)
	movl	%ecx, %edx
	cltq
	movb	%dl, -19(%rbp,%rax)
	movl	-36(%rbp), %eax
	movslq	%eax, %rdx
	imulq	$1717986919, %rdx, %rdx
	shrq	$32, %rdx
	sarl	$2, %edx
	sarl	$31, %eax
	movl	%eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, -36(%rbp)
.L11:
	cmpl	$0, -36(%rbp)
	jne	.L12
	jmp	.L13
.L14:
	movl	-24(%rbp), %eax
	cltq
	movzbl	-19(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, %edi
	call	putchar_unlocked@PLT
.L13:
	movl	-24(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -24(%rbp)
	testl	%eax, %eax
	jne	.L14
.L8:
	movq	-8(%rbp), %rax
	subq	%fs:40, %rax
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	put_uint, .-put_uint
	.globl	mcm
	.type	mcm, @function
mcm:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$88, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%rdi, -120(%rbp)
	movl	%esi, -124(%rbp)
	movq	%fs:40, %rcx
	movq	%rcx, -56(%rbp)
	xorl	%ecx, %ecx
	movq	%rsp, %rcx
	movq	%rcx, %rbx
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	subq	$1, %rcx
	movq	%rcx, -80(%rbp)
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	movq	%rcx, %r14
	movl	$0, %r15d
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	salq	$2, %rcx
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	subq	$1, %rsi
	movq	%rsi, -72(%rbp)
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	movq	%rsi, %r12
	movl	$0, %r13d
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	movq	%rsi, %rax
	movl	$0, %edx
	movq	%r13, %rdi
	imulq	%rax, %rdi
	movq	%rdx, %rsi
	imulq	%r12, %rsi
	addq	%rdi, %rsi
	mulq	%r12
	addq	%rdx, %rsi
	movq	%rsi, %rdx
	movl	-124(%rbp), %eax
	cltq
	movq	%rax, %r10
	movl	$0, %r11d
	movl	-124(%rbp), %eax
	cltq
	movq	%rax, %r8
	movl	$0, %r9d
	movq	%r11, %rdx
	imulq	%r8, %rdx
	movq	%r9, %rax
	imulq	%r10, %rax
	leaq	(%rdx,%rax), %rsi
	movq	%r10, %rax
	mulq	%r8
	addq	%rdx, %rsi
	movq	%rsi, %rdx
	movl	-124(%rbp), %eax
	movslq	%eax, %rdx
	movl	-124(%rbp), %eax
	cltq
	imulq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	movl	$16, %eax
	subq	$1, %rax
	addq	%rdx, %rax
	movl	$16, %edi
	movl	$0, %edx
	divq	%rdi
	imulq	$16, %rax, %rax
	movq	%rax, %rsi
	andq	$-4096, %rsi
	movq	%rsp, %rdx
	subq	%rsi, %rdx
.L17:
	cmpq	%rdx, %rsp
	je	.L18
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	jmp	.L17
.L18:
	movq	%rax, %rdx
	andl	$4095, %edx
	subq	%rdx, %rsp
	movq	%rax, %rdx
	andl	$4095, %edx
	testq	%rdx, %rdx
	je	.L19
	andl	$4095, %eax
	subq	$8, %rax
	addq	%rsp, %rax
	orq	$0, (%rax)
.L19:
	movq	%rsp, %rax
	addq	$3, %rax
	shrq	$2, %rax
	salq	$2, %rax
	movq	%rax, -64(%rbp)
	movl	$0, -108(%rbp)
	jmp	.L20
.L23:
	movl	$0, -104(%rbp)
	jmp	.L21
.L22:
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movq	-64(%rbp), %rax
	movl	-104(%rbp), %edx
	movslq	%edx, %rdi
	movl	-108(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	addq	%rdi, %rdx
	movl	$268435456, (%rax,%rdx,4)
	addl	$1, -104(%rbp)
.L21:
	movl	-104(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L22
	addl	$1, -108(%rbp)
.L20:
	movl	-108(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L23
	movl	$0, -100(%rbp)
	jmp	.L24
.L25:
	movq	%rcx, %rdx
	shrq	$2, %rdx
	movq	-64(%rbp), %rax
	leaq	1(%rdx), %rsi
	movl	-100(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	movl	$0, (%rax,%rdx,4)
	addl	$1, -100(%rbp)
.L24:
	movl	-100(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L25
	movl	$0, -96(%rbp)
	jmp	.L26
.L31:
	movl	$0, -92(%rbp)
	jmp	.L27
.L30:
	movl	-92(%rbp), %edx
	movl	-96(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -84(%rbp)
	movl	-92(%rbp), %eax
	movl	%eax, -88(%rbp)
	jmp	.L28
.L29:
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movq	-64(%rbp), %rax
	movl	-88(%rbp), %edx
	movslq	%edx, %rdi
	movl	-92(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	addq	%rdi, %rdx
	movl	(%rax,%rdx,4), %r8d
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movl	-88(%rbp), %eax
	leal	1(%rax), %edi
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %edx
	movslq	%edx, %r9
	movslq	%edi, %rdx
	imulq	%rsi, %rdx
	addq	%r9, %rdx
	movl	(%rax,%rdx,4), %eax
	leal	(%r8,%rax), %esi
	movl	-92(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-120(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %edx
	movl	-88(%rbp), %eax
	cltq
	addq	$1, %rax
	leaq	0(,%rax,4), %rdi
	movq	-120(%rbp), %rax
	addq	%rdi, %rax
	movl	(%rax), %eax
	imull	%eax, %edx
	movl	-84(%rbp), %eax
	cltq
	addq	$1, %rax
	leaq	0(,%rax,4), %rdi
	movq	-120(%rbp), %rax
	addq	%rdi, %rax
	movl	(%rax), %eax
	imull	%edx, %eax
	leal	(%rsi,%rax), %edx
	movq	%rcx, %rdi
	shrq	$2, %rdi
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %esi
	movslq	%esi, %r8
	movl	-92(%rbp), %esi
	movslq	%esi, %rsi
	imulq	%rdi, %rsi
	addq	%r8, %rsi
	movl	(%rax,%rsi,4), %eax
	movq	%rcx, %rdi
	shrq	$2, %rdi
	cmpl	%eax, %edx
	cmovg	%eax, %edx
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %esi
	movslq	%esi, %r8
	movl	-92(%rbp), %esi
	movslq	%esi, %rsi
	imulq	%rdi, %rsi
	addq	%r8, %rsi
	movl	%edx, (%rax,%rsi,4)
	addl	$1, -88(%rbp)
.L28:
	movl	-88(%rbp), %eax
	cmpl	-84(%rbp), %eax
	jl	.L29
	addl	$1, -92(%rbp)
.L27:
	movl	-124(%rbp), %eax
	subl	-96(%rbp), %eax
	cmpl	%eax, -92(%rbp)
	jl	.L30
	addl	$1, -96(%rbp)
.L26:
	movl	-96(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L31
	movl	-124(%rbp), %eax
	leal	-1(%rax), %edx
	movq	-64(%rbp), %rax
	movslq	%edx, %rdx
	movl	(%rax,%rdx,4), %eax
	movq	%rbx, %rsp
	movq	-56(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L33
	call	__stack_chk_fail@PLT
.L33:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	mcm, .-mcm
	.globl	main
	.type	main, @function
main:
.LFB3:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 12, -40
	.cfi_offset 3, -48
	movl	%edi, -68(%rbp)
	movq	%rsi, -80(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -40(%rbp)
	xorl	%eax, %eax
	movq	%rsp, %rax
	movq	%rax, %r12
	movl	$0, %eax
	call	get_uint
	movl	%eax, -60(%rbp)
	movl	-60(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rdx
	subq	$1, %rdx
	movq	%rdx, -56(%rbp)
	movslq	%eax, %rdx
	movq	%rdx, -96(%rbp)
	movq	$0, -88(%rbp)
	movslq	%eax, %rdx
	movq	%rdx, %r14
	movl	$0, %r15d
	cltq
	leaq	0(,%rax,4), %rdx
	movl	$16, %eax
	subq	$1, %rax
	addq	%rdx, %rax
	movl	$16, %esi
	movl	$0, %edx
	divq	%rsi
	imulq	$16, %rax, %rax
	movq	%rax, %rcx
	andq	$-4096, %rcx
	movq	%rsp, %rdx
	subq	%rcx, %rdx
.L35:
	cmpq	%rdx, %rsp
	je	.L36
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	jmp	.L35
.L36:
	movq	%rax, %rdx
	andl	$4095, %edx
	subq	%rdx, %rsp
	movq	%rax, %rdx
	andl	$4095, %edx
	testq	%rdx, %rdx
	je	.L37
	andl	$4095, %eax
	subq	$8, %rax
	addq	%rsp, %rax
	orq	$0, (%rax)
.L37:
	movq	%rsp, %rax
	addq	$3, %rax
	shrq	$2, %rax
	salq	$2, %rax
	movq	%rax, -48(%rbp)
	movl	$0, -64(%rbp)
	jmp	.L38
.L39:
	movl	$0, %eax
	call	get_uint
	movq	-48(%rbp), %rdx
	movl	-64(%rbp), %ecx
	movslq	%ecx, %rcx
	movl	%eax, (%rdx,%rcx,4)
	movl	-64(%rbp), %eax
	leal	1(%rax), %ebx
	movl	$0, %eax
	call	get_uint
	movq	-48(%rbp), %rdx
	movslq	%ebx, %rcx
	movl	%eax, (%rdx,%rcx,4)
	addl	$1, -64(%rbp)
.L38:
	movl	-64(%rbp), %eax
	cmpl	-60(%rbp), %eax
	jl	.L39
	movl	-60(%rbp), %edx
	movq	-48(%rbp), %rax
	movl	%edx, %esi
	movq	%rax, %rdi
	call	mcm
	movl	%eax, %edi
	call	put_uint
	movl	$10, %edi
	call	putchar_unlocked@PLT
	movl	$0, %eax
	movq	%r12, %rsp
	movq	-40(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L41
	call	__stack_chk_fail@PLT
.L41:
	leaq	-32(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
train
	.file	"temp.c"
	.text
	.globl	get_uint
	.type	get_uint, @function
get_uint:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	movl	$0, -8(%rbp)
	call	getchar_unlocked@PLT
	movl	%eax, -4(%rbp)
	cmpl	$47, -4(%rbp)
	jle	.L2
	cmpl	$57, -4(%rbp)
	jle	.L5
.L2:
	movl	-4(%rbp), %eax
	jmp	.L4
.L7:
	movl	-8(%rbp), %edx
	movl	%edx, %eax
	sall	$2, %eax
	addl	%edx, %eax
	addl	%eax, %eax
	movl	%eax, %edx
	movl	-4(%rbp), %eax
	andl	$15, %eax
	addl	%edx, %eax
	movl	%eax, -8(%rbp)
	call	getchar_unlocked@PLT
	movl	%eax, -4(%rbp)
.L5:
	cmpl	$47, -4(%rbp)
	jle	.L6
	cmpl	$57, -4(%rbp)
	jle	.L7
.L6:
	movl	-8(%rbp), %eax
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	get_uint, .-get_uint
	.globl	put_uint
	.type	put_uint, @function
put_uint:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movl	%edi, -36(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	cmpl	$0, -36(%rbp)
	jne	.L9
	movl	$48, %edi
	call	putchar_unlocked@PLT
	jmp	.L8
.L9:
	movl	$0, -24(%rbp)
	jmp	.L11
.L12:
	movl	-36(%rbp), %edx
	movslq	%edx, %rax
	imulq	$1717986919, %rax, %rax
	shrq	$32, %rax
	sarl	$2, %eax
	movl	%edx, %esi
	sarl	$31, %esi
	subl	%esi, %eax
	movl	%eax, %ecx
	movl	%ecx, %eax
	sall	$2, %eax
	addl	%ecx, %eax
	addl	%eax, %eax
	movl	%edx, %ecx
	subl	%eax, %ecx
	movl	%ecx, %eax
	leal	48(%rax), %ecx
	movl	-24(%rbp), %eax
	leal	1(%rax), %edx
	movl	%edx, -24(%rbp)
	movl	%ecx, %edx
	cltq
	movb	%dl, -19(%rbp,%rax)
	movl	-36(%rbp), %eax
	movslq	%eax, %rdx
	imulq	$1717986919, %rdx, %rdx
	shrq	$32, %rdx
	sarl	$2, %edx
	sarl	$31, %eax
	movl	%eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, -36(%rbp)
.L11:
	cmpl	$0, -36(%rbp)
	jne	.L12
	jmp	.L13
.L14:
	movl	-24(%rbp), %eax
	cltq
	movzbl	-19(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, %edi
	call	putchar_unlocked@PLT
.L13:
	movl	-24(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -24(%rbp)
	testl	%eax, %eax
	jne	.L14
.L8:
	movq	-8(%rbp), %rax
	subq	%fs:40, %rax
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	put_uint, .-put_uint
	.globl	mcm
	.type	mcm, @function
mcm:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$88, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	movq	%rdi, -120(%rbp)
	movl	%esi, -124(%rbp)
	movq	%fs:40, %rcx
	movq	%rcx, -56(%rbp)
	xorl	%ecx, %ecx
	movq	%rsp, %rcx
	movq	%rcx, %rbx
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	subq	$1, %rcx
	movq	%rcx, -80(%rbp)
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	movq	%rcx, %r14
	movl	$0, %r15d
	movl	-124(%rbp), %ecx
	movslq	%ecx, %rcx
	salq	$2, %rcx
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	subq	$1, %rsi
	movq	%rsi, -72(%rbp)
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	movq	%rsi, %r12
	movl	$0, %r13d
	movl	-124(%rbp), %esi
	movslq	%esi, %rsi
	movq	%rsi, %rax
	movl	$0, %edx
	movq	%r13, %rdi
	imulq	%rax, %rdi
	movq	%rdx, %rsi
	imulq	%r12, %rsi
	addq	%rdi, %rsi
	mulq	%r12
	addq	%rdx, %rsi
	movq	%rsi, %rdx
	movl	-124(%rbp), %eax
	cltq
	movq	%rax, %r10
	movl	$0, %r11d
	movl	-124(%rbp), %eax
	cltq
	movq	%rax, %r8
	movl	$0, %r9d
	movq	%r11, %rdx
	imulq	%r8, %rdx
	movq	%r9, %rax
	imulq	%r10, %rax
	leaq	(%rdx,%rax), %rsi
	movq	%r10, %rax
	mulq	%r8
	addq	%rdx, %rsi
	movq	%rsi, %rdx
	movl	-124(%rbp), %eax
	movslq	%eax, %rdx
	movl	-124(%rbp), %eax
	cltq
	imulq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	movl	$16, %eax
	subq	$1, %rax
	addq	%rdx, %rax
	movl	$16, %edi
	movl	$0, %edx
	divq	%rdi
	imulq	$16, %rax, %rax
	movq	%rax, %rsi
	andq	$-4096, %rsi
	movq	%rsp, %rdx
	subq	%rsi, %rdx
.L17:
	cmpq	%rdx, %rsp
	je	.L18
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	jmp	.L17
.L18:
	movq	%rax, %rdx
	andl	$4095, %edx
	subq	%rdx, %rsp
	movq	%rax, %rdx
	andl	$4095, %edx
	testq	%rdx, %rdx
	je	.L19
	andl	$4095, %eax
	subq	$8, %rax
	addq	%rsp, %rax
	orq	$0, (%rax)
.L19:
	movq	%rsp, %rax
	addq	$3, %rax
	shrq	$2, %rax
	salq	$2, %rax
	movq	%rax, -64(%rbp)
	movl	$0, -108(%rbp)
	jmp	.L20
.L23:
	movl	$0, -104(%rbp)
	jmp	.L21
.L22:
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movq	-64(%rbp), %rax
	movl	-104(%rbp), %edx
	movslq	%edx, %rdi
	movl	-108(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	addq	%rdi, %rdx
	movl	$268435456, (%rax,%rdx,4)
	addl	$1, -104(%rbp)
.L21:
	movl	-104(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L22
	addl	$1, -108(%rbp)
.L20:
	movl	-108(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L23
	movl	$0, -100(%rbp)
	jmp	.L24
.L25:
	movq	%rcx, %rdx
	shrq	$2, %rdx
	movq	-64(%rbp), %rax
	leaq	1(%rdx), %rsi
	movl	-100(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	movl	$0, (%rax,%rdx,4)
	addl	$1, -100(%rbp)
.L24:
	movl	-100(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L25
	movl	$0, -96(%rbp)
	jmp	.L26
.L31:
	movl	$0, -92(%rbp)
	jmp	.L27
.L30:
	movl	-92(%rbp), %edx
	movl	-96(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -84(%rbp)
	movl	-92(%rbp), %eax
	movl	%eax, -88(%rbp)
	jmp	.L28
.L29:
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movq	-64(%rbp), %rax
	movl	-88(%rbp), %edx
	movslq	%edx, %rdi
	movl	-92(%rbp), %edx
	movslq	%edx, %rdx
	imulq	%rsi, %rdx
	addq	%rdi, %rdx
	movl	(%rax,%rdx,4), %r8d
	movq	%rcx, %rsi
	shrq	$2, %rsi
	movl	-88(%rbp), %eax
	leal	1(%rax), %edi
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %edx
	movslq	%edx, %r9
	movslq	%edi, %rdx
	imulq	%rsi, %rdx
	addq	%r9, %rdx
	movl	(%rax,%rdx,4), %eax
	leal	(%r8,%rax), %esi
	movl	-92(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	movq	-120(%rbp), %rax
	addq	%rdx, %rax
	movl	(%rax), %edx
	movl	-88(%rbp), %eax
	cltq
	addq	$1, %rax
	leaq	0(,%rax,4), %rdi
	movq	-120(%rbp), %rax
	addq	%rdi, %rax
	movl	(%rax), %eax
	imull	%eax, %edx
	movl	-84(%rbp), %eax
	cltq
	addq	$1, %rax
	leaq	0(,%rax,4), %rdi
	movq	-120(%rbp), %rax
	addq	%rdi, %rax
	movl	(%rax), %eax
	imull	%edx, %eax
	leal	(%rsi,%rax), %edx
	movq	%rcx, %rdi
	shrq	$2, %rdi
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %esi
	movslq	%esi, %r8
	movl	-92(%rbp), %esi
	movslq	%esi, %rsi
	imulq	%rdi, %rsi
	addq	%r8, %rsi
	movl	(%rax,%rsi,4), %eax
	movq	%rcx, %rdi
	shrq	$2, %rdi
	cmpl	%eax, %edx
	cmovg	%eax, %edx
	movq	-64(%rbp), %rax
	movl	-84(%rbp), %esi
	movslq	%esi, %r8
	movl	-92(%rbp), %esi
	movslq	%esi, %rsi
	imulq	%rdi, %rsi
	addq	%r8, %rsi
	movl	%edx, (%rax,%rsi,4)
	addl	$1, -88(%rbp)
.L28:
	movl	-88(%rbp), %eax
	cmpl	-84(%rbp), %eax
	jl	.L29
	addl	$1, -92(%rbp)
.L27:
	movl	-124(%rbp), %eax
	subl	-96(%rbp), %eax
	cmpl	%eax, -92(%rbp)
	jl	.L30
	addl	$1, -96(%rbp)
.L26:
	movl	-96(%rbp), %eax
	cmpl	-124(%rbp), %eax
	jl	.L31
	movl	-124(%rbp), %eax
	leal	-1(%rax), %edx
	movq	-64(%rbp), %rax
	movslq	%edx, %rdx
	movl	(%rax,%rdx,4), %eax
	movq	%rbx, %rsp
	movq	-56(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L33
	call	__stack_chk_fail@PLT
.L33:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	mcm, .-mcm
	.globl	main
	.type	main, @function
main:
.LFB3:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 12, -40
	.cfi_offset 3, -48
	movl	%edi, -68(%rbp)
	movq	%rsi, -80(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -40(%rbp)
	xorl	%eax, %eax
	movq	%rsp, %rax
	movq	%rax, %r12
	movl	$0, %eax
	call	get_uint
	movl	%eax, -60(%rbp)
	movl	-60(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rdx
	subq	$1, %rdx
	movq	%rdx, -56(%rbp)
	movslq	%eax, %rdx
	movq	%rdx, -96(%rbp)
	movq	$0, -88(%rbp)
	movslq	%eax, %rdx
	movq	%rdx, %r14
	movl	$0, %r15d
	cltq
	leaq	0(,%rax,4), %rdx
	movl	$16, %eax
	subq	$1, %rax
	addq	%rdx, %rax
	movl	$16, %esi
	movl	$0, %edx
	divq	%rsi
	imulq	$16, %rax, %rax
	movq	%rax, %rcx
	andq	$-4096, %rcx
	movq	%rsp, %rdx
	subq	%rcx, %rdx
.L35:
	cmpq	%rdx, %rsp
	je	.L36
	subq	$4096, %rsp
	orq	$0, 4088(%rsp)
	jmp	.L35
.L36:
	movq	%rax, %rdx
	andl	$4095, %edx
	subq	%rdx, %rsp
	movq	%rax, %rdx
	andl	$4095, %edx
	testq	%rdx, %rdx
	je	.L37
	andl	$4095, %eax
	subq	$8, %rax
	addq	%rsp, %rax
	orq	$0, (%rax)
.L37:
	movq	%rsp, %rax
	addq	$3, %rax
	shrq	$2, %rax
	salq	$2, %rax
	movq	%rax, -48(%rbp)
	movl	$0, -64(%rbp)
	jmp	.L38
.L39:
	movl	$0, %eax
	call	get_uint
	movq	-48(%rbp), %rdx
	movl	-64(%rbp), %ecx
	movslq	%ecx, %rcx
	movl	%eax, (%rdx,%rcx,4)
	movl	-64(%rbp), %eax
	leal	1(%rax), %ebx
	movl	$0, %eax
	call	get_uint
	movq	-48(%rbp), %rdx
	movslq	%ebx, %rcx
	movl	%eax, (%rdx,%rcx,4)
	addl	$1, -64(%rbp)
.L38:
	movl	-64(%rbp), %eax
	cmpl	-60(%rbp), %eax
	jl	.L39
	movl	-60(%rbp), %edx
	movq	-48(%rbp), %rax
	movl	%edx, %esi
	movq	%rax, %rdi
	call	mcm
	movl	%eax, %edi
	call	put_uint
	movl	$10, %edi
	call	putchar_unlocked@PLT
	movl	$0, %eax
	movq	%r12, %rsp
	movq	-40(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L41
	call	__stack_chk_fail@PLT
.L41:
	leaq	-32(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.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:
