	.file	"392521.c"
	.intel_syntax noprefix
	.text
	.globl	sortarr
	.type	sortarr, @function
sortarr:
.LFB6:
	.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 -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -12[rbp], 0
	jmp	.L2
.L6:
	mov	DWORD PTR -8[rbp], 0
	jmp	.L3
.L5:
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	rdx, QWORD PTR [rax]
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rcx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rcx
	mov	rax, QWORD PTR [rax]
	cmp	rdx, rax
	jge	.L4
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	lea	rcx, 0[0+rdx*8]
	mov	rdx, QWORD PTR -24[rbp]
	add	rdx, rcx
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR [rdx], rax
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -24[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	mov	QWORD PTR [rdx], rax
.L4:
	add	DWORD PTR -8[rbp], 1
.L3:
	mov	eax, DWORD PTR -8[rbp]
	cmp	eax, DWORD PTR -12[rbp]
	jl	.L5
	add	DWORD PTR -12[rbp], 1
.L2:
	mov	eax, DWORD PTR -12[rbp]
	cmp	eax, DWORD PTR -28[rbp]
	jl	.L6
	mov	eax, 0
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	sortarr, .-sortarr
	.section	.rodata
.LC0:
	.string	"%d%lld%lld%d"
.LC1:
	.string	"%lld"
.LC2:
	.string	"%lld "
.LC3:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.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, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 3872
	mov	DWORD PTR -16148[rbp], edi
	mov	QWORD PTR -16160[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	jmp	.L9
.L16:
	lea	rsi, -16128[rbp]
	lea	rcx, -16104[rbp]
	lea	rdx, -16112[rbp]
	lea	rax, -16132[rbp]
	mov	r8, rsi
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	DWORD PTR -16124[rbp], 0
	jmp	.L10
.L11:
	lea	rdx, -16096[rbp]
	mov	eax, DWORD PTR -16124[rbp]
	cdqe
	sal	rax, 3
	add	rax, rdx
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	add	DWORD PTR -16124[rbp], 1
.L10:
	mov	eax, DWORD PTR -16132[rbp]
	cmp	DWORD PTR -16124[rbp], eax
	jl	.L11
	mov	DWORD PTR -16120[rbp], 0
	jmp	.L12
.L13:
	lea	rdx, -8048[rbp]
	mov	eax, DWORD PTR -16120[rbp]
	cdqe
	sal	rax, 3
	add	rax, rdx
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	add	DWORD PTR -16120[rbp], 1
.L12:
	mov	eax, DWORD PTR -16132[rbp]
	cmp	DWORD PTR -16120[rbp], eax
	jl	.L13
	mov	edx, DWORD PTR -16132[rbp]
	lea	rax, -16096[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	sortarr
	mov	DWORD PTR -16116[rbp], 0
	jmp	.L14
.L15:
	mov	eax, DWORD PTR -16116[rbp]
	cdqe
	mov	rax, QWORD PTR -16096[rbp+rax*8]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -16116[rbp], 1
.L14:
	mov	eax, DWORD PTR -16132[rbp]
	cmp	DWORD PTR -16116[rbp], eax
	jl	.L15
.L9:
	lea	rax, -16136[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	cmp	eax, 1
	je	.L16
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L18
	call	__stack_chk_fail@PLT
.L18:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.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	"392521.c"
	.text
	.align	2
	.global	sortarr
	.syntax unified
	.arm
	.fpu softvfp
	.type	sortarr, %function
sortarr:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #28
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L2
.L6:
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L3
.L5:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldmia	r3, {r0-r1}
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	cmp	r0, r2
	sbcs	r3, r1, r3
	bge	.L4
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	mov	r3, r2
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldr	r2, [fp, #-16]
	lsl	r2, r2, #3
	ldr	r1, [fp, #-24]
	add	r1, r1, r2
	ldmia	r3, {r2-r3}
	stm	r1, {r2-r3}
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-24]
	add	r1, r2, r3
	ldr	r3, [fp, #-8]
	mov	r2, r3
	asr	r3, r2, #31
	stm	r1, {r2-r3}
.L4:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L3:
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-16]
	cmp	r2, r3
	blt	.L5
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L2:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-28]
	cmp	r2, r3
	blt	.L6
	mov	r2, #0
	mov	r3, #0
	mov	r0, r2
	mov	r1, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	sortarr, .-sortarr
	.section	.rodata
	.align	2
.LC0:
	.ascii	"%d%lld%lld%d\000"
	.align	2
.LC1:
	.ascii	"%lld\000"
	.align	2
.LC2:
	.ascii	"%lld \000"
	.align	2
.LC3:
	.ascii	"%d\000"
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 16136
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16128
	sub	sp, sp, #16
	sub	r3, fp, #12288
	sub	r3, r3, #4
	str	r0, [r3, #-3844]
	sub	r3, fp, #12288
	sub	r3, r3, #4
	str	r1, [r3, #-3848]
	ldr	r3, .L19
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	b	.L9
.L16:
	sub	r0, fp, #16064
	sub	r0, r0, #4
	sub	r0, r0, #32
	sub	r2, fp, #16064
	sub	r2, r2, #4
	sub	r2, r2, #40
	sub	r1, fp, #16064
	sub	r1, r1, #4
	sub	r1, r1, #60
	sub	r3, fp, #16064
	sub	r3, r3, #4
	sub	r3, r3, #56
	str	r3, [sp]
	mov	r3, r0
	ldr	r0, .L19+4
	bl	__isoc99_scanf
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #-3828]
	b	.L10
.L11:
	sub	r3, fp, #16064
	sub	r3, r3, #4
	sub	r3, r3, #24
	sub	r2, fp, #12288
	sub	r2, r2, #4
	ldr	r2, [r2, #-3828]
	lsl	r2, r2, #3
	add	r3, r3, r2
	mov	r1, r3
	ldr	r0, .L19+8
	bl	__isoc99_scanf
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3828]
	add	r3, r3, #1
	str	r3, [r2, #-3828]
.L10:
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3836]
	sub	r2, fp, #12288
	sub	r2, r2, #4
	ldr	r2, [r2, #-3828]
	cmp	r2, r3
	blt	.L11
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #-3824]
	b	.L12
.L13:
	sub	r3, fp, #8000
	sub	r3, r3, #4
	sub	r3, r3, #48
	sub	r2, fp, #12288
	sub	r2, r2, #4
	ldr	r2, [r2, #-3824]
	lsl	r2, r2, #3
	add	r3, r3, r2
	mov	r1, r3
	ldr	r0, .L19+8
	bl	__isoc99_scanf
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3824]
	add	r3, r3, #1
	str	r3, [r2, #-3824]
.L12:
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3836]
	sub	r2, fp, #12288
	sub	r2, r2, #4
	ldr	r2, [r2, #-3824]
	cmp	r2, r3
	blt	.L13
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r2, [r3, #-3836]
	sub	r3, fp, #16064
	sub	r3, r3, #4
	sub	r3, r3, #24
	mov	r1, r2
	mov	r0, r3
	bl	sortarr
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #-3820]
	b	.L14
.L15:
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3820]
	lsl	r3, r3, #3
	add	r3, r2, r3
	sub	r3, r3, #3792
	sub	r3, r3, #8
	ldmia	r3, {r2-r3}
	ldr	r0, .L19+12
	bl	printf
	sub	r3, fp, #12288
	sub	r3, r3, #4
	mov	r2, r3
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3820]
	add	r3, r3, #1
	str	r3, [r2, #-3820]
.L14:
	sub	r3, fp, #12288
	sub	r3, r3, #4
	ldr	r3, [r3, #-3836]
	sub	r2, fp, #12288
	sub	r2, r2, #4
	ldr	r2, [r2, #-3820]
	cmp	r2, r3
	blt	.L15
.L9:
	sub	r3, fp, #16128
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L19+16
	bl	__isoc99_scanf
	mov	r3, r0
	cmp	r3, #1
	beq	.L16
	mov	r3, #0
	ldr	r2, .L19
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L18
	bl	__stack_chk_fail
.L18:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L20:
	.align	2
.L19:
	.word	.LC4
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
