	.file	"14200348.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"#define %*s %d"
.LC1:
	.string	"static char %s = {"
	.align 8
.LC2:
	.string	"Could not allocate memory for bitmap.\n"
.LC3:
	.string	"%*2s%2x%*s"
.LC4:
	.string	"static short %s = {"
.LC5:
	.string	"\n    "
.LC6:
	.string	"0x%04x, "
.LC7:
	.string	"0x%04x};\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 336
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -176[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	gets@PLT
	lea	rdx, -336[rbp]
	lea	rax, -176[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_sscanf@PLT
	lea	rax, -96[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	gets@PLT
	lea	rdx, -332[rbp]
	lea	rax, -96[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_sscanf@PLT
	lea	rax, -256[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	gets@PLT
	lea	rdx, -288[rbp]
	lea	rax, -256[rbp]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_sscanf@PLT
	mov	eax, DWORD PTR -336[rbp]
	add	eax, 7
	lea	edx, 7[rax]
	test	eax, eax
	cmovs	eax, edx
	sar	eax, 3
	mov	DWORD PTR -320[rbp], eax
	mov	eax, DWORD PTR -332[rbp]
	mov	edx, DWORD PTR -320[rbp]
	imul	eax, edx
	mov	DWORD PTR -316[rbp], eax
	mov	eax, DWORD PTR -316[rbp]
	mov	edi, eax
	mov	eax, 0
	call	malloc@PLT
	mov	QWORD PTR -304[rbp], rax
	cmp	QWORD PTR -304[rbp], 0
	jne	.L2
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 38
	mov	esi, 1
	lea	rdi, .LC2[rip]
	call	fwrite@PLT
	jmp	.L16
.L2:
	mov	DWORD PTR -328[rbp], 0
	jmp	.L4
.L5:
	mov	eax, DWORD PTR -328[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -304[rbp]
	add	rax, rdx
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	add	DWORD PTR -328[rbp], 1
.L4:
	mov	eax, DWORD PTR -328[rbp]
	cmp	eax, DWORD PTR -316[rbp]
	jl	.L5
	mov	eax, DWORD PTR -336[rbp]
	add	eax, 15
	lea	edx, 15[rax]
	test	eax, eax
	cmovs	eax, edx
	sar	eax, 4
	mov	DWORD PTR -312[rbp], eax
	mov	eax, DWORD PTR -332[rbp]
	mov	edx, DWORD PTR -312[rbp]
	imul	eax, edx
	mov	DWORD PTR -308[rbp], eax
	mov	eax, DWORD PTR -308[rbp]
	add	eax, eax
	mov	edi, eax
	mov	eax, 0
	call	malloc@PLT
	mov	QWORD PTR -296[rbp], rax
	cmp	QWORD PTR -296[rbp], 0
	jne	.L6
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 38
	mov	esi, 1
	lea	rdi, .LC2[rip]
	call	fwrite@PLT
	jmp	.L16
.L6:
	mov	DWORD PTR -328[rbp], 0
	mov	DWORD PTR -324[rbp], 0
	jmp	.L7
.L9:
	mov	eax, DWORD PTR -328[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -328[rbp], edx
	movsx	rdx, eax
	mov	rax, QWORD PTR -304[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	mov	edx, DWORD PTR -324[rbp]
	movsx	rdx, edx
	lea	rcx, [rdx+rdx]
	mov	rdx, QWORD PTR -296[rbp]
	add	rdx, rcx
	movzx	eax, al
	mov	WORD PTR [rdx], ax
	mov	eax, DWORD PTR -328[rbp]
	cdq
	idiv	DWORD PTR -320[rbp]
	mov	eax, edx
	test	eax, eax
	je	.L8
	mov	eax, DWORD PTR -328[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -328[rbp], edx
	movsx	rdx, eax
	mov	rax, QWORD PTR -304[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movzx	eax, al
	sal	eax, 8
	mov	edx, eax
	mov	eax, DWORD PTR -324[rbp]
	cdqe
	lea	rcx, [rax+rax]
	mov	rax, QWORD PTR -296[rbp]
	add	rax, rcx
	movzx	ecx, WORD PTR [rax]
	mov	esi, edx
	mov	eax, DWORD PTR -324[rbp]
	cdqe
	lea	rdx, [rax+rax]
	mov	rax, QWORD PTR -296[rbp]
	add	rax, rdx
	lea	edx, [rcx+rsi]
	mov	WORD PTR [rax], dx
.L8:
	add	DWORD PTR -324[rbp], 1
.L7:
	mov	eax, DWORD PTR -328[rbp]
	cmp	eax, DWORD PTR -316[rbp]
	jl	.L9
	lea	rax, -176[rbp]
	mov	rdi, rax
	call	puts@PLT
	lea	rax, -96[rbp]
	mov	rdi, rax
	call	puts@PLT
	lea	rax, -288[rbp]
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -328[rbp], 0
	jmp	.L10
.L14:
	mov	eax, DWORD PTR -328[rbp]
	and	eax, 7
	test	eax, eax
	jne	.L11
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
.L11:
	mov	eax, DWORD PTR -308[rbp]
	sub	eax, 1
	cmp	DWORD PTR -328[rbp], eax
	je	.L12
	mov	eax, DWORD PTR -328[rbp]
	cdqe
	lea	rdx, [rax+rax]
	mov	rax, QWORD PTR -296[rbp]
	add	rax, rdx
	movzx	eax, WORD PTR [rax]
	movzx	eax, ax
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L13
.L12:
	mov	eax, DWORD PTR -328[rbp]
	cdqe
	lea	rdx, [rax+rax]
	mov	rax, QWORD PTR -296[rbp]
	add	rax, rdx
	movzx	eax, WORD PTR [rax]
	movzx	eax, ax
	mov	esi, eax
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	printf@PLT
.L13:
	add	DWORD PTR -328[rbp], 1
.L10:
	mov	eax, DWORD PTR -328[rbp]
	cmp	eax, DWORD PTR -308[rbp]
	jl	.L14
	mov	eax, 0
	jmp	.L1
.L16:
.L1:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.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	"14200348.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"#define %*s %d\000"
	.align	2
.LC1:
	.ascii	"static char %s = {\000"
	.align	2
.LC2:
	.ascii	"Could not allocate memory for bitmap.\012\000"
	.align	2
.LC3:
	.ascii	"%*2s%2x%*s\000"
	.global	__aeabi_idivmod
	.align	2
.LC4:
	.ascii	"static short %s = {\000"
	.align	2
.LC5:
	.ascii	"\012    \000"
	.align	2
.LC6:
	.ascii	"0x%04x, \000"
	.align	2
.LC7:
	.ascii	"0x%04x};\012\000"
	.align	2
.LC8:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 320
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #320
	ldr	r3, .L18
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #168
	mov	r0, r3
	bl	gets
	sub	r2, fp, #320
	sub	r3, fp, #168
	ldr	r1, .L18+4
	mov	r0, r3
	bl	__isoc99_sscanf
	sub	r3, fp, #88
	mov	r0, r3
	bl	gets
	sub	r2, fp, #316
	sub	r3, fp, #88
	ldr	r1, .L18+4
	mov	r0, r3
	bl	__isoc99_sscanf
	sub	r3, fp, #248
	mov	r0, r3
	bl	gets
	sub	r2, fp, #280
	sub	r3, fp, #248
	ldr	r1, .L18+8
	mov	r0, r3
	bl	__isoc99_sscanf
	ldr	r3, [fp, #-320]
	add	r3, r3, #7
	add	r2, r3, #7
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #3
	str	r3, [fp, #-304]
	ldr	r2, [fp, #-316]
	ldr	r3, [fp, #-304]
	mul	r3, r2, r3
	str	r3, [fp, #-300]
	ldr	r0, [fp, #-300]
	bl	malloc
	str	r0, [fp, #-296]
	ldr	r3, [fp, #-296]
	cmp	r3, #0
	bne	.L2
	ldr	r3, .L18+12
	ldr	r3, [r3]
	mov	r2, #38
	mov	r1, #1
	ldr	r0, .L18+16
	bl	fwrite
	b	.L16
.L2:
	mov	r3, #0
	str	r3, [fp, #-312]
	b	.L4
.L5:
	ldr	r3, [fp, #-312]
	ldr	r2, [fp, #-296]
	add	r3, r2, r3
	mov	r1, r3
	ldr	r0, .L18+20
	bl	__isoc99_scanf
	ldr	r3, [fp, #-312]
	add	r3, r3, #1
	str	r3, [fp, #-312]
.L4:
	ldr	r2, [fp, #-312]
	ldr	r3, [fp, #-300]
	cmp	r2, r3
	blt	.L5
	ldr	r3, [fp, #-320]
	add	r3, r3, #15
	add	r2, r3, #15
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #4
	str	r3, [fp, #-292]
	ldr	r2, [fp, #-316]
	ldr	r3, [fp, #-292]
	mul	r3, r2, r3
	str	r3, [fp, #-288]
	ldr	r3, [fp, #-288]
	lsl	r3, r3, #1
	mov	r0, r3
	bl	malloc
	str	r0, [fp, #-284]
	ldr	r3, [fp, #-284]
	cmp	r3, #0
	bne	.L6
	ldr	r3, .L18+12
	ldr	r3, [r3]
	mov	r2, #38
	mov	r1, #1
	ldr	r0, .L18+16
	bl	fwrite
	b	.L16
.L6:
	mov	r3, #0
	str	r3, [fp, #-312]
	mov	r3, #0
	str	r3, [fp, #-308]
	b	.L7
.L9:
	ldr	r3, [fp, #-312]
	add	r2, r3, #1
	str	r2, [fp, #-312]
	mov	r2, r3
	ldr	r3, [fp, #-296]
	add	r3, r3, r2
	ldrb	r2, [r3]	@ zero_extendqisi2
	ldr	r3, [fp, #-308]
	lsl	r3, r3, #1
	ldr	r1, [fp, #-284]
	add	r3, r1, r3
	lsl	r2, r2, #16
	lsr	r2, r2, #16
	strh	r2, [r3]	@ movhi
	ldr	r3, [fp, #-312]
	ldr	r1, [fp, #-304]
	mov	r0, r3
	bl	__aeabi_idivmod
	mov	r3, r1
	cmp	r3, #0
	beq	.L8
	ldr	r3, [fp, #-312]
	add	r2, r3, #1
	str	r2, [fp, #-312]
	mov	r2, r3
	ldr	r3, [fp, #-296]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #8
	ldr	r2, [fp, #-308]
	lsl	r2, r2, #1
	ldr	r1, [fp, #-284]
	add	r2, r1, r2
	ldrh	r1, [r2]
	lsl	r3, r3, #16
	lsr	r2, r3, #16
	ldr	r3, [fp, #-308]
	lsl	r3, r3, #1
	ldr	r0, [fp, #-284]
	add	r3, r0, r3
	add	r2, r1, r2
	lsl	r2, r2, #16
	lsr	r2, r2, #16
	strh	r2, [r3]	@ movhi
.L8:
	ldr	r3, [fp, #-308]
	add	r3, r3, #1
	str	r3, [fp, #-308]
.L7:
	ldr	r2, [fp, #-312]
	ldr	r3, [fp, #-300]
	cmp	r2, r3
	blt	.L9
	sub	r3, fp, #168
	mov	r0, r3
	bl	puts
	sub	r3, fp, #88
	mov	r0, r3
	bl	puts
	sub	r3, fp, #280
	mov	r1, r3
	ldr	r0, .L18+24
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-312]
	b	.L10
.L14:
	ldr	r3, [fp, #-312]
	and	r3, r3, #7
	cmp	r3, #0
	bne	.L11
	ldr	r0, .L18+28
	bl	printf
.L11:
	ldr	r3, [fp, #-288]
	sub	r3, r3, #1
	ldr	r2, [fp, #-312]
	cmp	r2, r3
	beq	.L12
	ldr	r3, [fp, #-312]
	lsl	r3, r3, #1
	ldr	r2, [fp, #-284]
	add	r3, r2, r3
	ldrh	r3, [r3]
	mov	r1, r3
	ldr	r0, .L18+32
	bl	printf
	b	.L13
.L12:
	ldr	r3, [fp, #-312]
	lsl	r3, r3, #1
	ldr	r2, [fp, #-284]
	add	r3, r2, r3
	ldrh	r3, [r3]
	mov	r1, r3
	ldr	r0, .L18+36
	bl	printf
.L13:
	ldr	r3, [fp, #-312]
	add	r3, r3, #1
	str	r3, [fp, #-312]
.L10:
	ldr	r2, [fp, #-312]
	ldr	r3, [fp, #-288]
	cmp	r2, r3
	blt	.L14
	mov	r3, #0
	b	.L1
.L16:
.L1:
	ldr	r2, .L18
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L17
	bl	__stack_chk_fail
.L17:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L19:
	.align	2
.L18:
	.word	.LC8
	.word	.LC0
	.word	.LC1
	.word	stderr
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
