Given the following C code and assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
// Aizu Vol-5 0538: IOIOI
// 2017.9.1 bal4u@uu

#include <stdio.h>

char s[1000003];

int main()
{
	int n, m, ans, len;
	char *p, *e;

	while (scanf("%d", &n) && n) {
		scanf("%d%s", &m, s);
		p = s, e = s + m, len = 0, ans = 0;
		while (p < e) {
			if (*p == 'I' && *(p+1) == 'O') len++, p += 2;
			else {
				if (len > 0) {
					if (*p == 'O') len--;
					if (len >= n) ans += len - n + 1;
					len = 0;
				}
				p++;
			}
		}
		printf("%d\n", ans);
	}
	return 0;
}```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%s"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC1(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC2(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	s(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
	leaq	4(%rsp), %r15
	.p2align 4,,10
	.p2align 3
.L2:
	xorl	%eax, %eax
	movq	%r12, %rsi
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L10
	movl	(%rsp), %eax
	testl	%eax, %eax
	je	.L10
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movq	%r14, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	4(%rsp), %rsi
	addq	%rbx, %rsi
	cmpq	%rbx, %rsi
	jbe	.L13
	movl	(%rsp), %edi
	leaq	s(%rip), %rax
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	testl	%edx, %edx
	je	.L7
	cmpb	$79, %cl
	sete	%cl
	movzbl	%cl, %ecx
	subl	%ecx, %edx
.L8:
	cmpl	%edx, %edi
	jg	.L7
	subl	%edi, %edx
	leal	1(%r8,%rdx), %r8d
.L7:
	addq	$1, %rax
	xorl	%edx, %edx
.L6:
	cmpq	%rsi, %rax
	jnb	.L3
.L9:
	movzbl	(%rax), %ecx
	cmpb	$73, %cl
	jne	.L4
	cmpb	$79, 1(%rax)
	je	.L24
	testl	%edx, %edx
	jne	.L8
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L13:
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r8d, %edx
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L24:
	addl	$1, %edx
	addq	$2, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L25
	addq	$24, %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
.L25:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 1000003
s:
	.zero	1000003
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
Optimized Assembly Code:

user
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%s"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC1(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC2(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	s(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
	leaq	4(%rsp), %r15
	.p2align 4,,10
	.p2align 3
.L2:
	xorl	%eax, %eax
	movq	%r12, %rsi
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L10
	movl	(%rsp), %eax
	testl	%eax, %eax
	je	.L10
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movq	%r14, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	4(%rsp), %rsi
	addq	%rbx, %rsi
	cmpq	%rbx, %rsi
	jbe	.L13
	movl	(%rsp), %edi
	leaq	s(%rip), %rax
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	testl	%edx, %edx
	je	.L7
	cmpb	$79, %cl
	sete	%cl
	movzbl	%cl, %ecx
	subl	%ecx, %edx
.L8:
	cmpl	%edx, %edi
	jg	.L7
	subl	%edi, %edx
	leal	1(%r8,%rdx), %r8d
.L7:
	addq	$1, %rax
	xorl	%edx, %edx
.L6:
	cmpq	%rsi, %rax
	jnb	.L3
.L9:
	movzbl	(%rax), %ecx
	cmpb	$73, %cl
	jne	.L4
	cmpb	$79, 1(%rax)
	je	.L24
	testl	%edx, %edx
	jne	.L8
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L13:
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r8d, %edx
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L24:
	addl	$1, %edx
	addq	$2, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L25
	addq	$24, %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
.L25:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 1000003
s:
	.zero	1000003
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```
rule
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%s"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC1(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC2(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	s(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
	leaq	4(%rsp), %r15
	.p2align 4,,10
	.p2align 3
.L2:
	xorl	%eax, %eax
	movq	%r12, %rsi
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L10
	movl	(%rsp), %eax
	testl	%eax, %eax
	je	.L10
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movq	%r14, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	4(%rsp), %rsi
	addq	%rbx, %rsi
	cmpq	%rbx, %rsi
	jbe	.L13
	movl	(%rsp), %edi
	leaq	s(%rip), %rax
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	testl	%edx, %edx
	je	.L7
	cmpb	$79, %cl
	sete	%cl
	movzbl	%cl, %ecx
	subl	%ecx, %edx
.L8:
	cmpl	%edx, %edi
	jg	.L7
	subl	%edi, %edx
	leal	1(%r8,%rdx), %r8d
.L7:
	addq	$1, %rax
	xorl	%edx, %edx
.L6:
	cmpq	%rsi, %rax
	jnb	.L3
.L9:
	movzbl	(%rax), %ecx
	cmpb	$73, %cl
	jne	.L4
	cmpb	$79, 1(%rax)
	je	.L24
	testl	%edx, %edx
	jne	.L8
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L13:
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r8d, %edx
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L24:
	addl	$1, %edx
	addq	$2, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L25
	addq	$24, %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
.L25:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 1000003
s:
	.zero	1000003
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```
```c
// Aizu Vol-5 0538: IOIOI
// 2017.9.1 bal4u@uu

#include <stdio.h>

char s[1000003];

int main()
{
	int n, m, ans, len;
	char *p, *e;

	while (scanf("%d", &n) && n) {
		scanf("%d%s", &m, s);
		p = s, e = s + m, len = 0, ans = 0;
		while (p < e) {
			if (*p == 'I' && *(p+1) == 'O') len++, p += 2;
			else {
				if (len > 0) {
					if (*p == 'O') len--;
					if (len >= n) ans += len - n + 1;
					len = 0;
				}
				p++;
			}
		}
		printf("%d\n", ans);
	}
	return 0;
}```
Given the following C code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
// Aizu Vol-5 0538: IOIOI
// 2017.9.1 bal4u@uu

#include <stdio.h>

char s[1000003];

int main()
{
	int n, m, ans, len;
	char *p, *e;

	while (scanf("%d", &n) && n) {
		scanf("%d%s", &m, s);
		p = s, e = s + m, len = 0, ans = 0;
		while (p < e) {
			if (*p == 'I' && *(p+1) == 'O') len++, p += 2;
			else {
				if (len > 0) {
					if (*p == 'O') len--;
					if (len >= n) ans += len - n + 1;
					len = 0;
				}
				p++;
			}
		}
		printf("%d\n", ans);
	}
	return 0;
}```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
Optimized Assembly Code:

1
13
OIIOIOIOIIOIO
2
13
OOIOIOIOIIOII
0
 1
13
OOIOIOIOIIOII
3
13
OOIOIOIOIIOII
0
 1
25
OOIOIOIOIIOII
3
13
OOJOIOIOIIOIJ
0
 1
25
OIIOIOIOIIOIO
0
13
OOJOIOIOIIOIJ
0
 1
25
OOIOIOIOIIOII
1
13
JIOIIOIOIOIOO
0
 1
25
OIIOIOIOIIOIO
1
13
OOJOIOIOIIOIJ
0
 1
25
OOIOIOIOIJOII
0
13
OOIOIOIOIIOIJ
0
 1
31
JIOHIOIOIOHOO
0
2
IOOOHPIOJHOIJ
-3
 1
25
OIIOIOHOIIOIO
3
25
OOJOIOIOIIOIJ
0
 1
31
OOIOIOHOIHOIJ
0
19
OOHOIOIOIIOIJ
-2

3
2
 4
1
 4
0
 5
 4
4
 5
3
 3
 4
 4
0
 2

Given the following C code and assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
// Aizu Vol-5 0538: IOIOI
// 2017.9.1 bal4u@uu

#include <stdio.h>

char s[1000003];

int main()
{
	int n, m, ans, len;
	char *p, *e;

	while (scanf("%d", &n) && n) {
		scanf("%d%s", &m, s);
		p = s, e = s + m, len = 0, ans = 0;
		while (p < e) {
			if (*p == 'I' && *(p+1) == 'O') len++, p += 2;
			else {
				if (len > 0) {
					if (*p == 'O') len--;
					if (len >= n) ans += len - n + 1;
					len = 0;
				}
				p++;
			}
		}
		printf("%d\n", ans);
	}
	return 0;
}```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%s"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC1(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC2(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	s(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
	leaq	4(%rsp), %r15
	.p2align 4,,10
	.p2align 3
.L2:
	xorl	%eax, %eax
	movq	%r12, %rsi
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L10
	movl	(%rsp), %eax
	testl	%eax, %eax
	je	.L10
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movq	%r14, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	4(%rsp), %rsi
	addq	%rbx, %rsi
	cmpq	%rbx, %rsi
	jbe	.L13
	movl	(%rsp), %edi
	leaq	s(%rip), %rax
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	testl	%edx, %edx
	je	.L7
	cmpb	$79, %cl
	sete	%cl
	movzbl	%cl, %ecx
	subl	%ecx, %edx
.L8:
	cmpl	%edx, %edi
	jg	.L7
	subl	%edi, %edx
	leal	1(%r8,%rdx), %r8d
.L7:
	addq	$1, %rax
	xorl	%edx, %edx
.L6:
	cmpq	%rsi, %rax
	jnb	.L3
.L9:
	movzbl	(%rax), %ecx
	cmpb	$73, %cl
	jne	.L4
	cmpb	$79, 1(%rax)
	je	.L24
	testl	%edx, %edx
	jne	.L8
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L13:
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r8d, %edx
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L24:
	addl	$1, %edx
	addq	$2, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L25
	addq	$24, %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
.L25:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 1000003
s:
	.zero	1000003
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
Optimized Assembly Code:

train
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%s"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	.LC0(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC1(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC2(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	s(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
	leaq	4(%rsp), %r15
	.p2align 4,,10
	.p2align 3
.L2:
	xorl	%eax, %eax
	movq	%r12, %rsi
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L10
	movl	(%rsp), %eax
	testl	%eax, %eax
	je	.L10
	movq	%r15, %rsi
	movq	%rbx, %rdx
	movq	%r14, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	4(%rsp), %rsi
	addq	%rbx, %rsi
	cmpq	%rbx, %rsi
	jbe	.L13
	movl	(%rsp), %edi
	leaq	s(%rip), %rax
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L4:
	testl	%edx, %edx
	je	.L7
	cmpb	$79, %cl
	sete	%cl
	movzbl	%cl, %ecx
	subl	%ecx, %edx
.L8:
	cmpl	%edx, %edi
	jg	.L7
	subl	%edi, %edx
	leal	1(%r8,%rdx), %r8d
.L7:
	addq	$1, %rax
	xorl	%edx, %edx
.L6:
	cmpq	%rsi, %rax
	jnb	.L3
.L9:
	movzbl	(%rax), %ecx
	cmpb	$73, %cl
	jne	.L4
	cmpb	$79, 1(%rax)
	je	.L24
	testl	%edx, %edx
	jne	.L8
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L13:
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%r8d, %edx
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L24:
	addl	$1, %edx
	addq	$2, %rax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L25
	addq	$24, %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
.L25:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 1000003
s:
	.zero	1000003
	.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:
```