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>
int N,K,cnt;
int A[101][101];
int d[101], snuke[101];
int main(void) {
	scanf("%d %d", &N, &K);
	for(int j = 0; j < K; j++){
		scanf("%d", &d[j]);
		for(int i = 0; i < d[j]; i++){
			scanf("%d", &A[j][i]);
			int tmp = A[j][i];
		}
	}
	cnt = N;
	for(int k = 1; k <= N;k++){
		for(int j = 0; j < K; j++){
			for(int i = 0; i < d[j]; i++){
				int tmp = A[j][i];
				if(tmp == k){
					cnt--;
					j = K;
					i = d[j];
				}
			}
		}
	}

	printf("%d", cnt);

	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	N
	.bss
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	K
	.align 4
	.type	K, @object
	.size	K, 4
K:
	.zero	4
	.globl	cnt
	.align 4
	.type	cnt, @object
	.size	cnt, 4
cnt:
	.zero	4
	.globl	A
	.align 32
	.type	A, @object
	.size	A, 40804
A:
	.zero	40804
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 404
d:
	.zero	404
	.globl	snuke
	.align 32
	.type	snuke, @object
	.size	snuke, 404
snuke:
	.zero	404
	.section	.rodata
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
	.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
	subq	$32, %rsp
	leaq	K(%rip), %rax
	movq	%rax, %rdx
	leaq	N(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -28(%rbp)
	jmp	.L2
.L5:
	movl	-28(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -24(%rbp)
	jmp	.L3
.L4:
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-28(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-28(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -4(%rbp)
	addl	$1, -24(%rbp)
.L3:
	movl	-28(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L4
	addl	$1, -28(%rbp)
.L2:
	movl	K(%rip), %eax
	cmpl	%eax, -28(%rbp)
	jl	.L5
	movl	N(%rip), %eax
	movl	%eax, cnt(%rip)
	movl	$1, -20(%rbp)
	jmp	.L6
.L12:
	movl	$0, -16(%rbp)
	jmp	.L7
.L11:
	movl	$0, -12(%rbp)
	jmp	.L8
.L10:
	movl	-12(%rbp), %eax
	movslq	%eax, %rcx
	movl	-16(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -8(%rbp)
	movl	-8(%rbp), %eax
	cmpl	-20(%rbp), %eax
	jne	.L9
	movl	cnt(%rip), %eax
	subl	$1, %eax
	movl	%eax, cnt(%rip)
	movl	K(%rip), %eax
	movl	%eax, -16(%rbp)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -12(%rbp)
.L9:
	addl	$1, -12(%rbp)
.L8:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L10
	addl	$1, -16(%rbp)
.L7:
	movl	K(%rip), %eax
	cmpl	%eax, -16(%rbp)
	jl	.L11
	addl	$1, -20(%rbp)
.L6:
	movl	N(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L12
	movl	cnt(%rip), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
	.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	K(%rip), %rdx
	leaq	N(%rip), %rsi
	xorl	%eax, %eax
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %rdi
	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
	leaq	.LC1(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$8, %rsp
	.cfi_def_cfa_offset 64
	call	__isoc99_scanf@PLT
	movl	K(%rip), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	d(%rip), %rbx
	xorl	%r13d, %r13d
	xorl	%r12d, %r12d
	.p2align 4,,10
	.p2align 3
.L4:
	movq	%rbx, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	xorl	%r15d, %r15d
	call	__isoc99_scanf@PLT
	leaq	A(%rip), %rax
	leaq	(%rax,%r13,4), %r14
	movl	(%rbx), %eax
	testl	%eax, %eax
	jle	.L6
	.p2align 4,,10
	.p2align 3
.L5:
	movq	%r14, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	addl	$1, %r15d
	call	__isoc99_scanf@PLT
	addq	$4, %r14
	cmpl	%r15d, (%rbx)
	jg	.L5
.L6:
	movl	K(%rip), %r11d
	addl	$1, %r12d
	addq	$4, %rbx
	addq	$101, %r13
	cmpl	%r12d, %r11d
	jg	.L4
.L2:
	movl	N(%rip), %r10d
	movl	%r10d, cnt(%rip)
	testl	%r10d, %r10d
	jle	.L9
	leal	1(%r10), %r13d
	xorl	%ebx, %ebx
	movl	$1, %esi
	leaq	d(%rip), %r12
	leaq	A(%rip), %rdi
	.p2align 4,,10
	.p2align 3
.L8:
	xorl	%r9d, %r9d
	testl	%r11d, %r11d
	jle	.L13
	.p2align 4,,10
	.p2align 3
.L15:
	movslq	%r9d, %rax
	xorl	%edx, %edx
	movl	(%r12,%rax,4), %r8d
	testl	%r8d, %r8d
	jle	.L11
	leaq	(%rax,%rax,4), %rcx
	leaq	(%rcx,%rcx,4), %rcx
	leaq	(%rax,%rcx,4), %rcx
	.p2align 4,,10
	.p2align 3
.L12:
	movslq	%edx, %rax
	addq	%rcx, %rax
	cmpl	%esi, (%rdi,%rax,4)
	je	.L29
	addl	$1, %edx
	cmpl	%r8d, %edx
	jl	.L12
.L11:
	addl	$1, %r9d
	cmpl	%r11d, %r9d
	jl	.L15
	.p2align 4,,10
	.p2align 3
.L13:
	addl	$1, %esi
	cmpl	%r13d, %esi
	jne	.L8
	testb	%bl, %bl
	je	.L9
	movl	%r10d, cnt(%rip)
.L9:
	movl	cnt(%rip), %edx
	movq	%rbp, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	addq	$8, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L29:
	.cfi_restore_state
	movl	%r11d, %r9d
	subl	$1, %r10d
	movl	$1, %ebx
	addl	$1, %r9d
	cmpl	%r11d, %r9d
	jl	.L15
	jmp	.L13
	.cfi_endproc
.LFE39:
	.size	main, .-main
	.globl	snuke
	.bss
	.align 32
	.type	snuke, @object
	.size	snuke, 404
snuke:
	.zero	404
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 404
d:
	.zero	404
	.globl	A
	.align 32
	.type	A, @object
	.size	A, 40804
A:
	.zero	40804
	.globl	cnt
	.align 4
	.type	cnt, @object
	.size	cnt, 4
cnt:
	.zero	4
	.globl	K
	.align 4
	.type	K, @object
	.size	K, 4
K:
	.zero	4
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.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"
.LC1:
	.string	"%d"
	.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	K(%rip), %rdx
	leaq	N(%rip), %rsi
	xorl	%eax, %eax
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %rdi
	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
	leaq	.LC1(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$8, %rsp
	.cfi_def_cfa_offset 64
	call	__isoc99_scanf@PLT
	movl	K(%rip), %r11d
	testl	%r11d, %r11d
	jle	.L2
	leaq	d(%rip), %rbx
	xorl	%r13d, %r13d
	xorl	%r12d, %r12d
	.p2align 4,,10
	.p2align 3
.L4:
	movq	%rbx, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	xorl	%r15d, %r15d
	call	__isoc99_scanf@PLT
	leaq	A(%rip), %rax
	leaq	(%rax,%r13,4), %r14
	movl	(%rbx), %eax
	testl	%eax, %eax
	jle	.L6
	.p2align 4,,10
	.p2align 3
.L5:
	movq	%r14, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	addl	$1, %r15d
	call	__isoc99_scanf@PLT
	addq	$4, %r14
	cmpl	%r15d, (%rbx)
	jg	.L5
.L6:
	movl	K(%rip), %r11d
	addl	$1, %r12d
	addq	$4, %rbx
	addq	$101, %r13
	cmpl	%r12d, %r11d
	jg	.L4
.L2:
	movl	N(%rip), %r10d
	movl	%r10d, cnt(%rip)
	testl	%r10d, %r10d
	jle	.L9
	leal	1(%r10), %r13d
	xorl	%ebx, %ebx
	movl	$1, %esi
	leaq	d(%rip), %r12
	leaq	A(%rip), %rdi
	.p2align 4,,10
	.p2align 3
.L8:
	xorl	%r9d, %r9d
	testl	%r11d, %r11d
	jle	.L13
	.p2align 4,,10
	.p2align 3
.L15:
	movslq	%r9d, %rax
	xorl	%edx, %edx
	movl	(%r12,%rax,4), %r8d
	testl	%r8d, %r8d
	jle	.L11
	leaq	(%rax,%rax,4), %rcx
	leaq	(%rcx,%rcx,4), %rcx
	leaq	(%rax,%rcx,4), %rcx
	.p2align 4,,10
	.p2align 3
.L12:
	movslq	%edx, %rax
	addq	%rcx, %rax
	cmpl	%esi, (%rdi,%rax,4)
	je	.L29
	addl	$1, %edx
	cmpl	%r8d, %edx
	jl	.L12
.L11:
	addl	$1, %r9d
	cmpl	%r11d, %r9d
	jl	.L15
	.p2align 4,,10
	.p2align 3
.L13:
	addl	$1, %esi
	cmpl	%r13d, %esi
	jne	.L8
	testb	%bl, %bl
	je	.L9
	movl	%r10d, cnt(%rip)
.L9:
	movl	cnt(%rip), %edx
	movq	%rbp, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	addq	$8, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L29:
	.cfi_restore_state
	movl	%r11d, %r9d
	subl	$1, %r10d
	movl	$1, %ebx
	addl	$1, %r9d
	cmpl	%r11d, %r9d
	jl	.L15
	jmp	.L13
	.cfi_endproc
.LFE39:
	.size	main, .-main
	.globl	snuke
	.bss
	.align 32
	.type	snuke, @object
	.size	snuke, 404
snuke:
	.zero	404
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 404
d:
	.zero	404
	.globl	A
	.align 32
	.type	A, @object
	.size	A, 40804
A:
	.zero	40804
	.globl	cnt
	.align 4
	.type	cnt, @object
	.size	cnt, 4
cnt:
	.zero	4
	.globl	K
	.align 4
	.type	K, @object
	.size	K, 4
K:
	.zero	4
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.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>
int N,K,cnt;
int A[101][101];
int d[101], snuke[101];
int main(void) {
	scanf("%d %d", &N, &K);
	for(int j = 0; j < K; j++){
		scanf("%d", &d[j]);
		for(int i = 0; i < d[j]; i++){
			scanf("%d", &A[j][i]);
			int tmp = A[j][i];
		}
	}
	cnt = N;
	for(int k = 1; k <= N;k++){
		for(int j = 0; j < K; j++){
			for(int i = 0; i < d[j]; i++){
				int tmp = A[j][i];
				if(tmp == k){
					cnt--;
					j = K;
					i = d[j];
				}
			}
		}
	}

	printf("%d", cnt);

	return 0;
}
3 1
2
1 3
1
3
 5 1
2
1 3
1
3
 3 3
0
3
1
3
1
3
 0 -1
2
1 2
5
-1
 6 -2
1
0 0
0
-1
 12 -2
1
0 0
0
-1
 4 -8
-2
1 0
0
0
 7 -14
-2
1 0
0
0
 21 -2
0
0 0
0
-2
 5 -2
1
0 1
0
-1

1 3 1 0 6 12 4 7 21 5
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>
int N,K,cnt;
int A[101][101];
int d[101], snuke[101];
int main(void) {
	scanf("%d %d", &N, &K);
	for(int j = 0; j < K; j++){
		scanf("%d", &d[j]);
		for(int i = 0; i < d[j]; i++){
			scanf("%d", &A[j][i]);
			int tmp = A[j][i];
		}
	}
	cnt = N;
	for(int k = 1; k <= N;k++){
		for(int j = 0; j < K; j++){
			for(int i = 0; i < d[j]; i++){
				int tmp = A[j][i];
				if(tmp == k){
					cnt--;
					j = K;
					i = d[j];
				}
			}
		}
	}

	printf("%d", cnt);

	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	N
	.bss
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	K
	.align 4
	.type	K, @object
	.size	K, 4
K:
	.zero	4
	.globl	cnt
	.align 4
	.type	cnt, @object
	.size	cnt, 4
cnt:
	.zero	4
	.globl	A
	.align 32
	.type	A, @object
	.size	A, 40804
A:
	.zero	40804
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 404
d:
	.zero	404
	.globl	snuke
	.align 32
	.type	snuke, @object
	.size	snuke, 404
snuke:
	.zero	404
	.section	.rodata
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
	.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
	subq	$32, %rsp
	leaq	K(%rip), %rax
	movq	%rax, %rdx
	leaq	N(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -28(%rbp)
	jmp	.L2
.L5:
	movl	-28(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -24(%rbp)
	jmp	.L3
.L4:
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-28(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-28(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -4(%rbp)
	addl	$1, -24(%rbp)
.L3:
	movl	-28(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L4
	addl	$1, -28(%rbp)
.L2:
	movl	K(%rip), %eax
	cmpl	%eax, -28(%rbp)
	jl	.L5
	movl	N(%rip), %eax
	movl	%eax, cnt(%rip)
	movl	$1, -20(%rbp)
	jmp	.L6
.L12:
	movl	$0, -16(%rbp)
	jmp	.L7
.L11:
	movl	$0, -12(%rbp)
	jmp	.L8
.L10:
	movl	-12(%rbp), %eax
	movslq	%eax, %rcx
	movl	-16(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -8(%rbp)
	movl	-8(%rbp), %eax
	cmpl	-20(%rbp), %eax
	jne	.L9
	movl	cnt(%rip), %eax
	subl	$1, %eax
	movl	%eax, cnt(%rip)
	movl	K(%rip), %eax
	movl	%eax, -16(%rbp)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -12(%rbp)
.L9:
	addl	$1, -12(%rbp)
.L8:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L10
	addl	$1, -16(%rbp)
.L7:
	movl	K(%rip), %eax
	cmpl	%eax, -16(%rbp)
	jl	.L11
	addl	$1, -20(%rbp)
.L6:
	movl	N(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L12
	movl	cnt(%rip), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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	N
	.bss
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	K
	.align 4
	.type	K, @object
	.size	K, 4
K:
	.zero	4
	.globl	cnt
	.align 4
	.type	cnt, @object
	.size	cnt, 4
cnt:
	.zero	4
	.globl	A
	.align 32
	.type	A, @object
	.size	A, 40804
A:
	.zero	40804
	.globl	d
	.align 32
	.type	d, @object
	.size	d, 404
d:
	.zero	404
	.globl	snuke
	.align 32
	.type	snuke, @object
	.size	snuke, 404
snuke:
	.zero	404
	.section	.rodata
.LC0:
	.string	"%d %d"
.LC1:
	.string	"%d"
	.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
	subq	$32, %rsp
	leaq	K(%rip), %rax
	movq	%rax, %rdx
	leaq	N(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -28(%rbp)
	jmp	.L2
.L5:
	movl	-28(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -24(%rbp)
	jmp	.L3
.L4:
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-28(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-28(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -4(%rbp)
	addl	$1, -24(%rbp)
.L3:
	movl	-28(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L4
	addl	$1, -28(%rbp)
.L2:
	movl	K(%rip), %eax
	cmpl	%eax, -28(%rbp)
	jl	.L5
	movl	N(%rip), %eax
	movl	%eax, cnt(%rip)
	movl	$1, -20(%rbp)
	jmp	.L6
.L12:
	movl	$0, -16(%rbp)
	jmp	.L7
.L11:
	movl	$0, -12(%rbp)
	jmp	.L8
.L10:
	movl	-12(%rbp), %eax
	movslq	%eax, %rcx
	movl	-16(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rsi
	addq	%rsi, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	A(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -8(%rbp)
	movl	-8(%rbp), %eax
	cmpl	-20(%rbp), %eax
	jne	.L9
	movl	cnt(%rip), %eax
	subl	$1, %eax
	movl	%eax, cnt(%rip)
	movl	K(%rip), %eax
	movl	%eax, -16(%rbp)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -12(%rbp)
.L9:
	addl	$1, -12(%rbp)
.L8:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	d(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L10
	addl	$1, -16(%rbp)
.L7:
	movl	K(%rip), %eax
	cmpl	%eax, -16(%rbp)
	jl	.L11
	addl	$1, -20(%rbp)
.L6:
	movl	N(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L12
	movl	cnt(%rip), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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:
