	.file	"514104.c"
	.intel_syntax noprefix
	.text
	.globl	stack_create
	.type	stack_create, @function
stack_create:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	DWORD PTR -20[rbp], edi
	mov	edi, 16
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	mov	rdi, rax
	call	malloc@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR 8[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR [rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	stack_create, .-stack_create
	.globl	stack_delete
	.type	stack_delete, @function
stack_delete:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	free@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	stack_delete, .-stack_delete
	.globl	stack_get_top
	.type	stack_get_top, @function
stack_get_top:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 8[rax]
	movzx	eax, BYTE PTR [rax]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	stack_get_top, .-stack_get_top
	.globl	stack_pop
	.type	stack_pop, @function
stack_pop:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 8[rax]
	lea	rdx, -1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	stack_pop, .-stack_pop
	.globl	stack_push
	.type	stack_push, @function
stack_push:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	eax, esi
	mov	BYTE PTR -12[rbp], al
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 8[rax]
	lea	rdx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 8[rax]
	movzx	edx, BYTE PTR -12[rbp]
	mov	BYTE PTR [rax], dl
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	stack_push, .-stack_push
	.globl	stack_is_empty
	.type	stack_is_empty, @function
stack_is_empty:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR 8[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR [rax]
	cmp	rdx, rax
	sete	al
	movzx	eax, al
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	stack_is_empty, .-stack_is_empty
	.globl	pivot
	.type	pivot, @function
pivot:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	eax, edi
	mov	BYTE PTR -4[rbp], al
	movsx	eax, BYTE PTR -4[rbp]
	sub	eax, 40
	cmp	eax, 7
	ja	.L11
	mov	eax, eax
	lea	rdx, 0[0+rax*4]
	lea	rax, .L13[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cdqe
	lea	rdx, .L13[rip]
	add	rax, rdx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L13:
	.long	.L17-.L13
	.long	.L11-.L13
	.long	.L16-.L13
	.long	.L15-.L13
	.long	.L11-.L13
	.long	.L14-.L13
	.long	.L11-.L13
	.long	.L12-.L13
	.text
.L15:
	mov	eax, 1
	jmp	.L18
.L14:
	mov	eax, 1
	jmp	.L18
.L16:
	mov	eax, 11
	jmp	.L18
.L12:
	mov	eax, 11
	jmp	.L18
.L17:
	mov	eax, -1
	jmp	.L18
.L11:
	mov	eax, 0
.L18:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	pivot, .-pivot
	.section	.rodata
.LC0:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB13:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 2072
	.cfi_offset 3, -24
	mov	DWORD PTR -2068[rbp], edi
	mov	QWORD PTR -2080[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	lea	rax, -2056[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	call	getchar@PLT
	jmp	.L20
.L35:
	lea	rax, -2032[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	gets@PLT
	lea	rax, -2032[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	DWORD PTR -2044[rbp], eax
	mov	eax, DWORD PTR -2044[rbp]
	mov	edi, eax
	call	stack_create
	mov	QWORD PTR -2040[rbp], rax
	mov	DWORD PTR -2048[rbp], 0
	mov	eax, DWORD PTR -2048[rbp]
	mov	DWORD PTR -2052[rbp], eax
	jmp	.L21
.L32:
	mov	eax, DWORD PTR -2052[rbp]
	cdqe
	movzx	eax, BYTE PTR -2032[rbp+rax]
	cmp	al, 57
	jg	.L22
	mov	eax, DWORD PTR -2052[rbp]
	cdqe
	movzx	eax, BYTE PTR -2032[rbp+rax]
	cmp	al, 47
	jle	.L22
	mov	eax, DWORD PTR -2048[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -2048[rbp], edx
	mov	edx, DWORD PTR -2052[rbp]
	movsx	rdx, edx
	movzx	edx, BYTE PTR -2032[rbp+rdx]
	cdqe
	mov	BYTE PTR -1024[rbp+rax], dl
	jmp	.L23
.L22:
	mov	eax, DWORD PTR -2052[rbp]
	cdqe
	movzx	eax, BYTE PTR -2032[rbp+rax]
	cmp	al, 40
	jne	.L24
	mov	rax, QWORD PTR -2040[rbp]
	mov	esi, 40
	mov	rdi, rax
	call	stack_push
	jmp	.L23
.L24:
	mov	eax, DWORD PTR -2052[rbp]
	cdqe
	movzx	eax, BYTE PTR -2032[rbp+rax]
	cmp	al, 41
	jne	.L28
	jmp	.L26
.L27:
	mov	eax, DWORD PTR -2048[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -2048[rbp], edx
	cdqe
	movzx	edx, BYTE PTR -2057[rbp]
	mov	BYTE PTR -1024[rbp+rax], dl
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_pop
.L26:
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_get_top
	mov	BYTE PTR -2057[rbp], al
	cmp	BYTE PTR -2057[rbp], 40
	jne	.L27
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_pop
	jmp	.L23
.L31:
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_get_top
	mov	BYTE PTR -2058[rbp], al
	movsx	eax, BYTE PTR -2058[rbp]
	mov	edi, eax
	call	pivot
	mov	ebx, eax
	mov	eax, DWORD PTR -2052[rbp]
	cdqe
	movzx	eax, BYTE PTR -2032[rbp+rax]
	movsx	eax, al
	mov	edi, eax
	call	pivot
	cmp	ebx, eax
	jl	.L38
	mov	eax, DWORD PTR -2048[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -2048[rbp], edx
	cdqe
	movzx	edx, BYTE PTR -2058[rbp]
	mov	BYTE PTR -1024[rbp+rax], dl
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_pop
.L28:
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_is_empty
	test	eax, eax
	je	.L31
	jmp	.L30
.L38:
	nop
.L30:
	mov	eax, DWORD PTR -2052[rbp]
	cdqe
	movzx	eax, BYTE PTR -2032[rbp+rax]
	movsx	edx, al
	mov	rax, QWORD PTR -2040[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	stack_push
.L23:
	add	DWORD PTR -2052[rbp], 1
.L21:
	mov	eax, DWORD PTR -2052[rbp]
	cmp	eax, DWORD PTR -2044[rbp]
	jl	.L32
	jmp	.L33
.L34:
	mov	ebx, DWORD PTR -2048[rbp]
	lea	eax, 1[rbx]
	mov	DWORD PTR -2048[rbp], eax
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_get_top
	movsx	rdx, ebx
	mov	BYTE PTR -1024[rbp+rdx], al
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_pop
.L33:
	mov	rax, QWORD PTR -2040[rbp]
	mov	rdi, rax
	call	stack_is_empty
	test	eax, eax
	je	.L34
	mov	eax, DWORD PTR -2048[rbp]
	cdqe
	mov	BYTE PTR -1024[rbp+rax], 0
	lea	rax, -1024[rbp]
	mov	rdi, rax
	call	puts@PLT
.L20:
	mov	eax, DWORD PTR -2056[rbp]
	lea	edx, -1[rax]
	mov	DWORD PTR -2056[rbp], edx
	test	eax, eax
	jne	.L35
	mov	eax, 0
	mov	rcx, QWORD PTR -24[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L37
	call	__stack_chk_fail@PLT
.L37:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.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:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"514104.c"
	.text
	.align	2
	.global	stack_create
	.syntax unified
	.arm
	.fpu softvfp
	.type	stack_create, %function
stack_create:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r0, #8
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	stack_create, .-stack_create
	.align	2
	.global	stack_delete
	.syntax unified
	.arm
	.fpu softvfp
	.type	stack_delete, %function
stack_delete:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r0, r3
	bl	free
	ldr	r0, [fp, #-8]
	bl	free
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	stack_delete, .-stack_delete
	.align	2
	.global	stack_get_top
	.syntax unified
	.arm
	.fpu softvfp
	.type	stack_get_top, %function
stack_get_top:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3, #4]
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	stack_get_top, .-stack_get_top
	.align	2
	.global	stack_pop
	.syntax unified
	.arm
	.fpu softvfp
	.type	stack_pop, %function
stack_pop:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3, #4]
	sub	r2, r3, #1
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	stack_pop, .-stack_pop
	.align	2
	.global	stack_push
	.syntax unified
	.arm
	.fpu softvfp
	.type	stack_push, %function
stack_push:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	mov	r3, r1
	strb	r3, [fp, #-9]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3, #4]
	add	r2, r3, #1
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3, #4]
	ldrb	r2, [fp, #-9]
	strb	r2, [r3]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	stack_push, .-stack_push
	.align	2
	.global	stack_is_empty
	.syntax unified
	.arm
	.fpu softvfp
	.type	stack_is_empty, %function
stack_is_empty:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	cmp	r2, r3
	moveq	r3, #1
	movne	r3, #0
	and	r3, r3, #255
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	stack_is_empty, .-stack_is_empty
	.align	2
	.global	pivot
	.syntax unified
	.arm
	.fpu softvfp
	.type	pivot, %function
pivot:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	mov	r3, r0
	strb	r3, [fp, #-5]
	ldrb	r3, [fp, #-5]	@ zero_extendqisi2
	sub	r3, r3, #40
	cmp	r3, #7
	ldrls	pc, [pc, r3, asl #2]
	b	.L11
.L13:
	.word	.L17
	.word	.L11
	.word	.L16
	.word	.L15
	.word	.L11
	.word	.L14
	.word	.L11
	.word	.L12
.L15:
	mov	r3, #1
	b	.L18
.L14:
	mov	r3, #1
	b	.L18
.L16:
	mov	r3, #11
	b	.L18
.L12:
	mov	r3, #11
	b	.L18
.L17:
	mvn	r3, #0
	b	.L18
.L11:
	mov	r3, #0
.L18:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	pivot, .-pivot
	.section	.rodata
	.align	2
.LC0:
	.ascii	"%d\000"
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 2040
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #2032
	sub	sp, sp, #12
	str	r0, [fp, #-2048]
	str	r1, [fp, #-2052]
	ldr	r3, .L39
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #2016
	sub	r3, r3, #12
	sub	r3, r3, #8
	mov	r1, r3
	ldr	r0, .L39+4
	bl	__isoc99_scanf
	bl	getchar
	b	.L20
.L35:
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	gets
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	str	r3, [fp, #-2024]
	ldr	r0, [fp, #-2024]
	bl	stack_create
	str	r0, [fp, #-2020]
	mov	r3, #0
	str	r3, [fp, #-2028]
	ldr	r3, [fp, #-2028]
	str	r3, [fp, #-2032]
	b	.L21
.L32:
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-2032]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #57
	bhi	.L22
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-2032]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #47
	bls	.L22
	ldr	r2, [fp, #-2028]
	add	r3, r2, #1
	str	r3, [fp, #-2028]
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, [fp, #-2032]
	add	r3, r3, r1
	ldrb	r1, [r3]	@ zero_extendqisi2
	sub	r3, fp, #12
	add	r3, r3, r2
	mov	r2, r1
	strb	r2, [r3, #-1004]
	b	.L23
.L22:
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-2032]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #40
	bne	.L24
	mov	r1, #40
	ldr	r0, [fp, #-2020]
	bl	stack_push
	b	.L23
.L24:
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-2032]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #41
	bne	.L28
	b	.L26
.L27:
	ldr	r3, [fp, #-2028]
	add	r2, r3, #1
	str	r2, [fp, #-2028]
	sub	r2, fp, #12
	add	r3, r2, r3
	ldrb	r2, [fp, #-2037]
	strb	r2, [r3, #-1004]
	ldr	r0, [fp, #-2020]
	bl	stack_pop
.L26:
	ldr	r0, [fp, #-2020]
	bl	stack_get_top
	mov	r3, r0
	strb	r3, [fp, #-2037]
	ldrb	r3, [fp, #-2037]	@ zero_extendqisi2
	cmp	r3, #40
	bne	.L27
	ldr	r0, [fp, #-2020]
	bl	stack_pop
	b	.L23
.L31:
	ldr	r0, [fp, #-2020]
	bl	stack_get_top
	mov	r3, r0
	strb	r3, [fp, #-2038]
	ldrb	r3, [fp, #-2038]	@ zero_extendqisi2
	mov	r0, r3
	bl	pivot
	mov	r4, r0
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-2032]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r0, r3
	bl	pivot
	mov	r3, r0
	cmp	r4, r3
	blt	.L38
	ldr	r3, [fp, #-2028]
	add	r2, r3, #1
	str	r2, [fp, #-2028]
	sub	r2, fp, #12
	add	r3, r2, r3
	ldrb	r2, [fp, #-2038]
	strb	r2, [r3, #-1004]
	ldr	r0, [fp, #-2020]
	bl	stack_pop
.L28:
	ldr	r0, [fp, #-2020]
	bl	stack_is_empty
	mov	r3, r0
	cmp	r3, #0
	beq	.L31
	b	.L30
.L38:
	nop
.L30:
	sub	r3, fp, #2000
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-2032]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r0, [fp, #-2020]
	bl	stack_push
.L23:
	ldr	r3, [fp, #-2032]
	add	r3, r3, #1
	str	r3, [fp, #-2032]
.L21:
	ldr	r2, [fp, #-2032]
	ldr	r3, [fp, #-2024]
	cmp	r2, r3
	blt	.L32
	b	.L33
.L34:
	ldr	r4, [fp, #-2028]
	add	r3, r4, #1
	str	r3, [fp, #-2028]
	ldr	r0, [fp, #-2020]
	bl	stack_get_top
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #12
	add	r3, r3, r4
	strb	r2, [r3, #-1004]
	ldr	r0, [fp, #-2020]
	bl	stack_pop
.L33:
	ldr	r0, [fp, #-2020]
	bl	stack_is_empty
	mov	r3, r0
	cmp	r3, #0
	beq	.L34
	sub	r2, fp, #1016
	ldr	r3, [fp, #-2028]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
	sub	r3, fp, #1016
	mov	r0, r3
	bl	puts
.L20:
	ldr	r3, [fp, #-2036]
	sub	r2, r3, #1
	str	r2, [fp, #-2036]
	cmp	r3, #0
	bne	.L35
	mov	r3, #0
	ldr	r2, .L39
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L37
	bl	__stack_chk_fail
.L37:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L40:
	.align	2
.L39:
	.word	.LC1
	.word	.LC0
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
