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>
char str[1025];
char ans[53];
int min(int a, int b) {
	if(a > b) return b;
	return a;
}
int max(int a, int b) {
	if(a > b) return a;
	return b;
}
int main() {
	int I, N;
	scanf("%d", &N);
	for(I = 0; I < N; ++ I) {
		scanf("%s", str);
		int n = 26;
		int Mi = 26, mi = 26;
		int i;
		for(i = 0; ;) {
			ans[n] = str[i];
			if(str[i + 1] == '-') {
				n ++;
				Mi = max(Mi, n);
				i += 3;
			} else if(str[i + 1] == '<') {
				n --;
				mi = min(mi, n);
				i += 3;
			} else {
				break;
			}
		}
		ans[Mi + 1] = 0;
		printf("%s\n", ans + mi);
	}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	str
	.bss
	.align 32
	.type	str, @object
	.size	str, 1025
str:
	.zero	1025
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 53
ans:
	.zero	53
	.text
	.globl	min
	.type	min, @function
min:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L2
	movl	-8(%rbp), %eax
	jmp	.L3
.L2:
	movl	-4(%rbp), %eax
.L3:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	min, .-min
	.globl	max
	.type	max, @function
max:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L5
	movl	-4(%rbp), %eax
	jmp	.L6
.L5:
	movl	-8(%rbp), %eax
.L6:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	max, .-max
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.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
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -28(%rbp)
	jmp	.L8
.L14:
	leaq	str(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$26, -24(%rbp)
	movl	$26, -20(%rbp)
	movl	$26, -16(%rbp)
	movl	$0, -12(%rbp)
.L13:
	movl	-12(%rbp), %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %edx
	movl	-24(%rbp), %eax
	cltq
	leaq	ans(%rip), %rcx
	movb	%dl, (%rax,%rcx)
	movl	-12(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %eax
	cmpb	$45, %al
	jne	.L9
	addl	$1, -24(%rbp)
	movl	-24(%rbp), %edx
	movl	-20(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	max
	movl	%eax, -20(%rbp)
	addl	$3, -12(%rbp)
	jmp	.L13
.L9:
	movl	-12(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %eax
	cmpb	$60, %al
	jne	.L17
	subl	$1, -24(%rbp)
	movl	-24(%rbp), %edx
	movl	-16(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	min
	movl	%eax, -16(%rbp)
	addl	$3, -12(%rbp)
	jmp	.L13
.L17:
	nop
	movl	-20(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	ans(%rip), %rdx
	movb	$0, (%rax,%rdx)
	movl	-16(%rbp), %eax
	cltq
	leaq	ans(%rip), %rdx
	addq	%rdx, %rax
	movq	%rax, %rdi
	call	puts@PLT
	addl	$1, -28(%rbp)
.L8:
	movl	-32(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jl	.L14
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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	min
	.type	min, @function
min:
.LFB23:
	.cfi_startproc
	endbr64
	cmpl	%esi, %edi
	movl	%esi, %eax
	cmovle	%edi, %eax
	ret
	.cfi_endproc
.LFE23:
	.size	min, .-min
	.p2align 4
	.globl	max
	.type	max, @function
max:
.LFB24:
	.cfi_startproc
	endbr64
	cmpl	%esi, %edi
	movl	%esi, %eax
	cmovge	%edi, %eax
	ret
	.cfi_endproc
.LFE24:
	.size	max, .-max
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB25:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	leaq	.LC0(%rip), %rdi
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$16, %rsp
	.cfi_def_cfa_offset 64
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %eax
	testl	%eax, %eax
	jle	.L5
	leaq	str(%rip), %r14
	xorl	%ebx, %ebx
	leaq	.LC1(%rip), %r12
	leaq	ans(%rip), %r13
	movq	%r14, %rbp
	.p2align 4,,10
	.p2align 3
.L10:
	movq	%r14, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	movq	%rbp, %r14
	call	__isoc99_scanf@PLT
	movl	$26, %edi
	movl	$26, %r8d
	leaq	str(%rip), %rcx
	movl	$26, %eax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L7:
	cmpb	$60, %dl
	jne	.L9
	subl	$1, %eax
	cmpl	%eax, %edi
	cmovg	%eax, %edi
.L8:
	addq	$3, %rcx
.L6:
	movzbl	(%rcx), %esi
	movslq	%eax, %rdx
	movb	%sil, 0(%r13,%rdx)
	movzbl	1(%rcx), %edx
	cmpb	$45, %dl
	jne	.L7
	addl	$1, %eax
	cmpl	%eax, %r8d
	cmovl	%eax, %r8d
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L9:
	addl	$1, %r8d
	movslq	%edi, %rdi
	addl	$1, %ebx
	movslq	%r8d, %r8
	addq	%r13, %rdi
	movb	$0, 0(%r13,%r8)
	call	puts@PLT
	cmpl	%ebx, 4(%rsp)
	jg	.L10
.L5:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L14
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L14:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	main, .-main
	.globl	ans
	.bss
	.align 32
	.type	ans, @object
	.size	ans, 53
ans:
	.zero	53
	.globl	str
	.align 32
	.type	str, @object
	.size	str, 1025
str:
	.zero	1025
	.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	min
	.type	min, @function
min:
.LFB23:
	.cfi_startproc
	endbr64
	cmpl	%esi, %edi
	movl	%esi, %eax
	cmovle	%edi, %eax
	ret
	.cfi_endproc
.LFE23:
	.size	min, .-min
	.p2align 4
	.globl	max
	.type	max, @function
max:
.LFB24:
	.cfi_startproc
	endbr64
	cmpl	%esi, %edi
	movl	%esi, %eax
	cmovge	%edi, %eax
	ret
	.cfi_endproc
.LFE24:
	.size	max, .-max
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB25:
	.cfi_startproc
	endbr64
	pushq	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	leaq	.LC0(%rip), %rdi
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	subq	$16, %rsp
	.cfi_def_cfa_offset 64
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %eax
	testl	%eax, %eax
	jle	.L5
	leaq	str(%rip), %r14
	xorl	%ebx, %ebx
	leaq	.LC1(%rip), %r12
	leaq	ans(%rip), %r13
	movq	%r14, %rbp
	.p2align 4,,10
	.p2align 3
.L10:
	movq	%r14, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	movq	%rbp, %r14
	call	__isoc99_scanf@PLT
	movl	$26, %edi
	movl	$26, %r8d
	leaq	str(%rip), %rcx
	movl	$26, %eax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L7:
	cmpb	$60, %dl
	jne	.L9
	subl	$1, %eax
	cmpl	%eax, %edi
	cmovg	%eax, %edi
.L8:
	addq	$3, %rcx
.L6:
	movzbl	(%rcx), %esi
	movslq	%eax, %rdx
	movb	%sil, 0(%r13,%rdx)
	movzbl	1(%rcx), %edx
	cmpb	$45, %dl
	jne	.L7
	addl	$1, %eax
	cmpl	%eax, %r8d
	cmovl	%eax, %r8d
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L9:
	addl	$1, %r8d
	movslq	%edi, %rdi
	addl	$1, %ebx
	movslq	%r8d, %r8
	addq	%r13, %rdi
	movb	$0, 0(%r13,%r8)
	call	puts@PLT
	cmpl	%ebx, 4(%rsp)
	jg	.L10
.L5:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L14
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 40
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
.L14:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	main, .-main
	.globl	ans
	.bss
	.align 32
	.type	ans, @object
	.size	ans, 53
ans:
	.zero	53
	.globl	str
	.align 32
	.type	str, @object
	.size	str, 1025
str:
	.zero	1025
	.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>
char str[1025];
char ans[53];
int min(int a, int b) {
	if(a > b) return b;
	return a;
}
int max(int a, int b) {
	if(a > b) return a;
	return b;
}
int main() {
	int I, N;
	scanf("%d", &N);
	for(I = 0; I < N; ++ I) {
		scanf("%s", str);
		int n = 26;
		int Mi = 26, mi = 26;
		int i;
		for(i = 0; ;) {
			ans[n] = str[i];
			if(str[i + 1] == '-') {
				n ++;
				Mi = max(Mi, n);
				i += 3;
			} else if(str[i + 1] == '<') {
				n --;
				mi = min(mi, n);
				i += 3;
			} else {
				break;
			}
		}
		ans[Mi + 1] = 0;
		printf("%s\n", ans + mi);
	}
	return 0;
}
4
a->f->c->b->d
b
 4
a->e->c->b->d
a
 4
a->f->c->b->d
a
 4
a->f->c->b->d
`
 4
a->e->c->b->d
c
 4
a->f->c->b->d
c
 4
`->f->c->b->d
c
 4
`->f->c->b->d
d
 4
a->e->c->b->d
d
 4
a->e->c->b->d
`

afcbd
b
b
b
 aecbd
a
a
a
 afcbd
a
a
a
 afcbd
`
`
`
 aecbd
c
c
c
 afcbd
c
c
c
 `fcbd
c
c
c
 `fcbd
d
d
d
 aecbd
d
d
d
 aecbd
`
`
`

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>
char str[1025];
char ans[53];
int min(int a, int b) {
	if(a > b) return b;
	return a;
}
int max(int a, int b) {
	if(a > b) return a;
	return b;
}
int main() {
	int I, N;
	scanf("%d", &N);
	for(I = 0; I < N; ++ I) {
		scanf("%s", str);
		int n = 26;
		int Mi = 26, mi = 26;
		int i;
		for(i = 0; ;) {
			ans[n] = str[i];
			if(str[i + 1] == '-') {
				n ++;
				Mi = max(Mi, n);
				i += 3;
			} else if(str[i + 1] == '<') {
				n --;
				mi = min(mi, n);
				i += 3;
			} else {
				break;
			}
		}
		ans[Mi + 1] = 0;
		printf("%s\n", ans + mi);
	}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	str
	.bss
	.align 32
	.type	str, @object
	.size	str, 1025
str:
	.zero	1025
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 53
ans:
	.zero	53
	.text
	.globl	min
	.type	min, @function
min:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L2
	movl	-8(%rbp), %eax
	jmp	.L3
.L2:
	movl	-4(%rbp), %eax
.L3:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	min, .-min
	.globl	max
	.type	max, @function
max:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L5
	movl	-4(%rbp), %eax
	jmp	.L6
.L5:
	movl	-8(%rbp), %eax
.L6:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	max, .-max
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.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
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -28(%rbp)
	jmp	.L8
.L14:
	leaq	str(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$26, -24(%rbp)
	movl	$26, -20(%rbp)
	movl	$26, -16(%rbp)
	movl	$0, -12(%rbp)
.L13:
	movl	-12(%rbp), %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %edx
	movl	-24(%rbp), %eax
	cltq
	leaq	ans(%rip), %rcx
	movb	%dl, (%rax,%rcx)
	movl	-12(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %eax
	cmpb	$45, %al
	jne	.L9
	addl	$1, -24(%rbp)
	movl	-24(%rbp), %edx
	movl	-20(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	max
	movl	%eax, -20(%rbp)
	addl	$3, -12(%rbp)
	jmp	.L13
.L9:
	movl	-12(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %eax
	cmpb	$60, %al
	jne	.L17
	subl	$1, -24(%rbp)
	movl	-24(%rbp), %edx
	movl	-16(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	min
	movl	%eax, -16(%rbp)
	addl	$3, -12(%rbp)
	jmp	.L13
.L17:
	nop
	movl	-20(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	ans(%rip), %rdx
	movb	$0, (%rax,%rdx)
	movl	-16(%rbp), %eax
	cltq
	leaq	ans(%rip), %rdx
	addq	%rdx, %rax
	movq	%rax, %rdi
	call	puts@PLT
	addl	$1, -28(%rbp)
.L8:
	movl	-32(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jl	.L14
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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	str
	.bss
	.align 32
	.type	str, @object
	.size	str, 1025
str:
	.zero	1025
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 53
ans:
	.zero	53
	.text
	.globl	min
	.type	min, @function
min:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L2
	movl	-8(%rbp), %eax
	jmp	.L3
.L2:
	movl	-4(%rbp), %eax
.L3:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	min, .-min
	.globl	max
	.type	max, @function
max:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L5
	movl	-4(%rbp), %eax
	jmp	.L6
.L5:
	movl	-8(%rbp), %eax
.L6:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	max, .-max
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%s"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.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
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -28(%rbp)
	jmp	.L8
.L14:
	leaq	str(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$26, -24(%rbp)
	movl	$26, -20(%rbp)
	movl	$26, -16(%rbp)
	movl	$0, -12(%rbp)
.L13:
	movl	-12(%rbp), %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %edx
	movl	-24(%rbp), %eax
	cltq
	leaq	ans(%rip), %rcx
	movb	%dl, (%rax,%rcx)
	movl	-12(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %eax
	cmpb	$45, %al
	jne	.L9
	addl	$1, -24(%rbp)
	movl	-24(%rbp), %edx
	movl	-20(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	max
	movl	%eax, -20(%rbp)
	addl	$3, -12(%rbp)
	jmp	.L13
.L9:
	movl	-12(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	str(%rip), %rdx
	movzbl	(%rax,%rdx), %eax
	cmpb	$60, %al
	jne	.L17
	subl	$1, -24(%rbp)
	movl	-24(%rbp), %edx
	movl	-16(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	min
	movl	%eax, -16(%rbp)
	addl	$3, -12(%rbp)
	jmp	.L13
.L17:
	nop
	movl	-20(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	ans(%rip), %rdx
	movb	$0, (%rax,%rdx)
	movl	-16(%rbp), %eax
	cltq
	leaq	ans(%rip), %rdx
	addq	%rdx, %rax
	movq	%rax, %rdi
	call	puts@PLT
	addl	$1, -28(%rbp)
.L8:
	movl	-32(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jl	.L14
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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:
