	.file	"822132.c"
	.intel_syntax noprefix
	.text
	.type	chomp, @function
chomp:
.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	QWORD PTR -24[rbp], rdi
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	QWORD PTR -8[rbp], rax
	jmp	.L2
.L4:
	sub	QWORD PTR -8[rbp], 1
.L2:
	cmp	QWORD PTR -8[rbp], 0
	je	.L3
	mov	rax, QWORD PTR -8[rbp]
	lea	rdx, -1[rax]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	cmp	al, 10
	je	.L4
.L3:
	mov	rdx, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -8[rbp]
	add	rax, rdx
	mov	BYTE PTR [rax], 0
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	chomp, .-chomp
	.section	.rodata
	.align 16
	.type	directions, @object
	.size	directions, 16
directions:
	.long	78
	.long	69
	.long	83
	.long	87
.LC0:
	.string	"line %u: "
	.align 8
.LC1:
	.string	"move %d,%d by %u in direction %c\n"
.LC2:
	.string	"move %c???\n"
	.text
	.type	move, @function
move:
.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	DWORD PTR -12[rbp], esi
	mov	DWORD PTR -16[rbp], edx
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, 50
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR 4[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	mov	edi, DWORD PTR -16[rbp]
	mov	esi, DWORD PTR -12[rbp]
	mov	r9d, edi
	mov	r8d, esi
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	cmp	DWORD PTR -16[rbp], 87
	je	.L6
	cmp	DWORD PTR -16[rbp], 87
	ja	.L7
	cmp	DWORD PTR -16[rbp], 83
	je	.L8
	cmp	DWORD PTR -16[rbp], 83
	ja	.L7
	cmp	DWORD PTR -16[rbp], 69
	je	.L9
	cmp	DWORD PTR -16[rbp], 78
	jne	.L7
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4[rax]
	mov	edx, eax
	mov	eax, DWORD PTR -12[rbp]
	add	eax, edx
	mov	edx, eax
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4[rax], edx
	jmp	.L10
.L9:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR [rax]
	mov	edx, eax
	mov	eax, DWORD PTR -12[rbp]
	add	eax, edx
	mov	edx, eax
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR [rax], edx
	jmp	.L10
.L8:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4[rax]
	sub	eax, DWORD PTR -12[rbp]
	mov	edx, eax
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4[rax], edx
	jmp	.L10
.L6:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR [rax]
	sub	eax, DWORD PTR -12[rbp]
	mov	edx, eax
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR [rax], edx
	jmp	.L10
.L7:
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, DWORD PTR -16[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 100
	call	exit@PLT
.L10:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	move, .-move
	.section	.rodata
.LC3:
	.string	"rb"
.LC4:
	.string	"dafuk %s?\n"
.LC5:
	.string	"%u%c"
.LC6:
	.string	"bad line(%s)\n"
.LC7:
	.string	"move too big in %s!\n"
.LC8:
	.string	"turn %c by %u degrees?\n"
.LC9:
	.string	"%s => direction is %c now\n"
.LC10:
	.string	"unknown direction(%s)\n"
.LC11:
	.string	"%d,%d\n"
	.align 8
.LC12:
	.string	"x=%d,y=%d => Manhattan dist is %d\n"
	.text
	.type	part1, @function
part1:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 208
	mov	QWORD PTR -200[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -200[rbp]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -160[rbp], rax
	cmp	QWORD PTR -160[rbp], 0
	jne	.L12
	mov	rax, QWORD PTR -200[rbp]
	mov	rdi, rax
	call	perror@PLT
	mov	edi, 111
	call	exit@PLT
.L12:
	mov	DWORD PTR -172[rbp], 0
	jmp	.L13
.L14:
	add	DWORD PTR -172[rbp], 1
	and	DWORD PTR -172[rbp], 3
.L13:
	mov	eax, DWORD PTR -172[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, directions[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, 69
	jne	.L14
	mov	eax, DWORD PTR -172[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, directions[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -168[rbp], eax
	mov	DWORD PTR -152[rbp], 0
	mov	DWORD PTR -148[rbp], 0
	jmp	.L15
.L29:
	lea	rax, -144[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rax, 1
	ja	.L16
	mov	rax, QWORD PTR stderr[rip]
	lea	rdx, -144[rbp]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 100
	call	exit@PLT
.L16:
	lea	rax, -144[rbp]
	mov	rdi, rax
	call	chomp
	mov	DWORD PTR -176[rbp], 0
	mov	BYTE PTR -177[rbp], 33
	lea	rdx, -177[rbp]
	lea	rax, -176[rbp]
	lea	rcx, -144[rbp]
	lea	rdi, 1[rcx]
	mov	rcx, rdx
	mov	rdx, rax
	lea	rsi, .LC5[rip]
	mov	eax, 0
	call	__isoc99_sscanf@PLT
	cmp	eax, 1
	je	.L17
	mov	rax, QWORD PTR stderr[rip]
	lea	rdx, -144[rbp]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 100
	call	exit@PLT
.L17:
	mov	eax, DWORD PTR -176[rbp]
	cmp	eax, 4660
	jbe	.L18
	mov	rax, QWORD PTR stderr[rip]
	lea	rdx, -144[rbp]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 100
	call	exit@PLT
.L18:
	mov	DWORD PTR -164[rbp], 1
	movzx	eax, BYTE PTR -144[rbp]
	movsx	eax, al
	sub	eax, 69
	cmp	eax, 18
	ja	.L19
	mov	eax, eax
	lea	rdx, 0[0+rax*4]
	lea	rax, .L21[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cdqe
	lea	rdx, .L21[rip]
	add	rax, rdx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L21:
	.long	.L20-.L21
	.long	.L24-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L23-.L21
	.long	.L19-.L21
	.long	.L20-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L22-.L21
	.long	.L20-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L19-.L21
	.long	.L20-.L21
	.text
.L20:
	movzx	eax, BYTE PTR -144[rbp]
	movsx	edx, al
	mov	ecx, DWORD PTR -176[rbp]
	lea	rax, -152[rbp]
	mov	esi, ecx
	mov	rdi, rax
	call	move
	jmp	.L25
.L23:
	mov	DWORD PTR -164[rbp], -1
.L22:
	mov	edx, DWORD PTR -176[rbp]
	mov	eax, edx
	shr	eax
	mov	ecx, eax
	mov	eax, 3054198967
	imul	rax, rcx
	shr	rax, 32
	shr	eax, 5
	imul	ecx, eax, 90
	mov	eax, edx
	sub	eax, ecx
	test	eax, eax
	je	.L27
	mov	ecx, DWORD PTR -176[rbp]
	movzx	eax, BYTE PTR -144[rbp]
	movsx	edx, al
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 100
	call	exit@PLT
.L28:
	mov	eax, DWORD PTR -176[rbp]
	sub	eax, 90
	mov	DWORD PTR -176[rbp], eax
	mov	eax, DWORD PTR -164[rbp]
	add	DWORD PTR -172[rbp], eax
	and	DWORD PTR -172[rbp], 3
.L27:
	mov	eax, DWORD PTR -176[rbp]
	test	eax, eax
	jne	.L28
	mov	eax, DWORD PTR -172[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, directions[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -168[rbp], eax
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, 126
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	ecx, DWORD PTR -168[rbp]
	lea	rdx, -144[rbp]
	lea	rsi, .LC9[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L25
.L24:
	mov	ecx, DWORD PTR -176[rbp]
	mov	edx, DWORD PTR -168[rbp]
	lea	rax, -152[rbp]
	mov	esi, ecx
	mov	rdi, rax
	call	move
	jmp	.L25
.L19:
	mov	rax, QWORD PTR stderr[rip]
	lea	rdx, -144[rbp]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 123
	call	exit@PLT
.L25:
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, 135
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	ecx, DWORD PTR -148[rbp]
	mov	edx, DWORD PTR -152[rbp]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC11[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
.L15:
	mov	rdx, QWORD PTR -160[rbp]
	lea	rax, -144[rbp]
	mov	esi, 123
	mov	rdi, rax
	call	fgets@PLT
	test	rax, rax
	jne	.L29
	mov	rax, QWORD PTR -160[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	eax, DWORD PTR -152[rbp]
	mov	ecx, eax
	sar	ecx, 31
	xor	eax, ecx
	mov	edx, eax
	sub	edx, ecx
	mov	eax, DWORD PTR -148[rbp]
	mov	ecx, eax
	sar	ecx, 31
	xor	eax, ecx
	sub	eax, ecx
	lea	ecx, [rdx+rax]
	mov	edx, DWORD PTR -148[rbp]
	mov	eax, DWORD PTR -152[rbp]
	mov	esi, eax
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L30
	call	__stack_chk_fail@PLT
.L30:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	part1, .-part1
	.section	.rodata
.LC13:
	.string	"usage: $0 file...\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB9:
	.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	QWORD PTR -32[rbp], rsi
	cmp	DWORD PTR -20[rbp], 1
	jg	.L32
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 18
	mov	esi, 1
	lea	rdi, .LC13[rip]
	call	fwrite@PLT
	mov	eax, 100
	jmp	.L33
.L32:
	mov	DWORD PTR -4[rbp], 1
	jmp	.L34
.L35:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -32[rbp]
	add	rax, rdx
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	part1
	add	DWORD PTR -4[rbp], 1
.L34:
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -20[rbp]
	jl	.L35
	mov	eax, 0
.L33:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.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	"822132.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	chomp, %function
chomp:
	@ 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]
	ldr	r0, [fp, #-16]
	bl	strlen
	str	r0, [fp, #-8]
	b	.L2
.L4:
	ldr	r3, [fp, #-8]
	sub	r3, r3, #1
	str	r3, [fp, #-8]
.L2:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L3
	ldr	r3, [fp, #-8]
	sub	r3, r3, #1
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	beq	.L4
.L3:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-8]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	chomp, .-chomp
	.section	.rodata
	.align	2
	.type	directions, %object
	.size	directions, 16
directions:
	.word	78
	.word	69
	.word	83
	.word	87
	.align	2
.LC0:
	.ascii	"line %u: \000"
	.align	2
.LC1:
	.ascii	"move %d,%d by %u in direction %c\012\000"
	.align	2
.LC2:
	.ascii	"move %c???\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	move, %function
move:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	str	r2, [fp, #-16]
	ldr	r3, .L13
	ldr	r3, [r3]
	mov	r2, #50
	ldr	r1, .L13+4
	mov	r0, r3
	bl	fprintf
	ldr	r3, .L13
	ldr	r0, [r3]
	ldr	r3, [fp, #-8]
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	ldr	r1, [r3, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-12]
	str	r3, [sp]
	mov	r3, r1
	ldr	r1, .L13+8
	bl	fprintf
	ldr	r3, [fp, #-16]
	sub	r3, r3, #69
	cmp	r3, #18
	ldrls	pc, [pc, r3, asl #2]
	b	.L6
.L8:
	.word	.L11
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L10
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L9
	.word	.L6
	.word	.L6
	.word	.L6
	.word	.L7
.L10:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3, #4]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r3, r2, r3
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	b	.L12
.L11:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	add	r3, r2, r3
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3]
	b	.L12
.L9:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3, #4]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	sub	r3, r2, r3
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	b	.L12
.L7:
	ldr	r3, [fp, #-8]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r3, [fp, #-12]
	sub	r3, r2, r3
	mov	r2, r3
	ldr	r3, [fp, #-8]
	str	r2, [r3]
	b	.L12
.L6:
	ldr	r3, .L13
	ldr	r3, [r3]
	ldr	r2, [fp, #-16]
	ldr	r1, .L13+12
	mov	r0, r3
	bl	fprintf
	mov	r0, #100
	bl	exit
.L12:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	stderr
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.size	move, .-move
	.section	.rodata
	.align	2
.LC3:
	.ascii	"rb\000"
	.align	2
.LC4:
	.ascii	"dafuk %s?\012\000"
	.align	2
.LC5:
	.ascii	"%u%c\000"
	.align	2
.LC6:
	.ascii	"bad line(%s)\012\000"
	.align	2
.LC7:
	.ascii	"move too big in %s!\012\000"
	.align	2
.LC8:
	.ascii	"turn %c by %u degrees?\012\000"
	.align	2
.LC9:
	.ascii	"%s => direction is %c now\012\000"
	.align	2
.LC10:
	.ascii	"unknown direction(%s)\012\000"
	.align	2
.LC11:
	.ascii	"%d,%d\012\000"
	.align	2
.LC12:
	.ascii	"x=%d,y=%d => Manhattan dist is %d\012\000"
	.align	2
.LC13:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	part1, %function
part1:
	@ args = 0, pretend = 0, frame = 168
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #168
	str	r0, [fp, #-168]
	ldr	r3, .L35
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r1, .L35+4
	ldr	r0, [fp, #-168]
	bl	fopen
	str	r0, [fp, #-144]
	ldr	r3, [fp, #-144]
	cmp	r3, #0
	bne	.L16
	ldr	r0, [fp, #-168]
	bl	perror
	mov	r0, #111
	bl	exit
.L16:
	mov	r3, #0
	str	r3, [fp, #-156]
	b	.L17
.L18:
	ldr	r3, [fp, #-156]
	add	r3, r3, #1
	str	r3, [fp, #-156]
	ldr	r3, [fp, #-156]
	and	r3, r3, #3
	str	r3, [fp, #-156]
.L17:
	ldr	r2, .L35+8
	ldr	r3, [fp, #-156]
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #69
	bne	.L18
	ldr	r2, .L35+8
	ldr	r3, [fp, #-156]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-152]
	mov	r3, #0
	str	r3, [fp, #-140]
	mov	r3, #0
	str	r3, [fp, #-136]
	b	.L19
.L33:
	sub	r3, fp, #132
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	cmp	r3, #1
	bhi	.L20
	ldr	r3, .L35+12
	ldr	r3, [r3]
	sub	r2, fp, #132
	ldr	r1, .L35+16
	mov	r0, r3
	bl	fprintf
	mov	r0, #100
	bl	exit
.L20:
	sub	r3, fp, #132
	mov	r0, r3
	bl	chomp
	mov	r3, #0
	str	r3, [fp, #-160]
	mov	r3, #33
	strb	r3, [fp, #-161]
	sub	r1, fp, #161
	sub	r2, fp, #160
	sub	r3, fp, #132
	add	r0, r3, #1
	mov	r3, r1
	ldr	r1, .L35+20
	bl	__isoc99_sscanf
	mov	r3, r0
	cmp	r3, #1
	beq	.L21
	ldr	r3, .L35+12
	ldr	r3, [r3]
	sub	r2, fp, #132
	ldr	r1, .L35+24
	mov	r0, r3
	bl	fprintf
	mov	r0, #100
	bl	exit
.L21:
	ldr	r3, [fp, #-160]
	ldr	r2, .L35+28
	cmp	r3, r2
	bls	.L22
	ldr	r3, .L35+12
	ldr	r3, [r3]
	sub	r2, fp, #132
	ldr	r1, .L35+32
	mov	r0, r3
	bl	fprintf
	mov	r0, #100
	bl	exit
.L22:
	mov	r3, #1
	str	r3, [fp, #-148]
	ldrb	r3, [fp, #-132]	@ zero_extendqisi2
	sub	r3, r3, #69
	cmp	r3, #18
	ldrls	pc, [pc, r3, asl #2]
	b	.L23
.L25:
	.word	.L24
	.word	.L28
	.word	.L23
	.word	.L23
	.word	.L23
	.word	.L23
	.word	.L23
	.word	.L27
	.word	.L23
	.word	.L24
	.word	.L23
	.word	.L23
	.word	.L23
	.word	.L26
	.word	.L24
	.word	.L23
	.word	.L23
	.word	.L23
	.word	.L24
.L24:
	ldr	r1, [fp, #-160]
	ldrb	r3, [fp, #-132]	@ zero_extendqisi2
	mov	r2, r3
	sub	r3, fp, #140
	mov	r0, r3
	bl	move
	b	.L29
.L27:
	mvn	r3, #0
	str	r3, [fp, #-148]
.L26:
	ldr	r1, [fp, #-160]
	lsr	r3, r1, #1
	ldr	r2, .L35+36
	umull	r0, r3, r2, r3
	lsr	r2, r3, #5
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #4
	sub	r2, r2, r3
	lsl	r3, r2, #1
	mov	r2, r3
	sub	r2, r1, r2
	cmp	r2, #0
	beq	.L31
	ldr	r3, .L35+12
	ldr	r0, [r3]
	ldrb	r3, [fp, #-132]	@ zero_extendqisi2
	mov	r2, r3
	ldr	r3, [fp, #-160]
	ldr	r1, .L35+40
	bl	fprintf
	mov	r0, #100
	bl	exit
.L32:
	ldr	r3, [fp, #-160]
	sub	r3, r3, #90
	str	r3, [fp, #-160]
	ldr	r2, [fp, #-156]
	ldr	r3, [fp, #-148]
	add	r3, r2, r3
	str	r3, [fp, #-156]
	ldr	r3, [fp, #-156]
	and	r3, r3, #3
	str	r3, [fp, #-156]
.L31:
	ldr	r3, [fp, #-160]
	cmp	r3, #0
	bne	.L32
	ldr	r2, .L35+8
	ldr	r3, [fp, #-156]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-152]
	ldr	r3, .L35+12
	ldr	r3, [r3]
	mov	r2, #126
	ldr	r1, .L35+44
	mov	r0, r3
	bl	fprintf
	ldr	r3, .L35+12
	ldr	r0, [r3]
	sub	r2, fp, #132
	ldr	r3, [fp, #-152]
	ldr	r1, .L35+48
	bl	fprintf
	b	.L29
.L28:
	ldr	r1, [fp, #-160]
	sub	r3, fp, #140
	ldr	r2, [fp, #-152]
	mov	r0, r3
	bl	move
	b	.L29
.L23:
	ldr	r3, .L35+12
	ldr	r3, [r3]
	sub	r2, fp, #132
	ldr	r1, .L35+52
	mov	r0, r3
	bl	fprintf
	mov	r0, #123
	bl	exit
.L29:
	ldr	r3, .L35+12
	ldr	r3, [r3]
	mov	r2, #135
	ldr	r1, .L35+44
	mov	r0, r3
	bl	fprintf
	ldr	r3, .L35+12
	ldr	r0, [r3]
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-136]
	ldr	r1, .L35+56
	bl	fprintf
.L19:
	sub	r3, fp, #132
	ldr	r2, [fp, #-144]
	mov	r1, #123
	mov	r0, r3
	bl	fgets
	mov	r3, r0
	cmp	r3, #0
	bne	.L33
	ldr	r0, [fp, #-144]
	bl	fclose
	ldr	r1, [fp, #-140]
	ldr	r0, [fp, #-136]
	ldr	r3, [fp, #-140]
	eor	r2, r3, r3, asr #31
	sub	r2, r2, r3, asr #31
	ldr	r3, [fp, #-136]
	cmp	r3, #0
	rsblt	r3, r3, #0
	add	r3, r2, r3
	mov	r2, r0
	ldr	r0, .L35+60
	bl	printf
	nop
	ldr	r3, .L35
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L34
	bl	__stack_chk_fail
.L34:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L36:
	.align	2
.L35:
	.word	.LC13
	.word	.LC3
	.word	directions
	.word	stderr
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	4660
	.word	.LC7
	.word	-1240768329
	.word	.LC8
	.word	.LC0
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.size	part1, .-part1
	.section	.rodata
	.align	2
.LC14:
	.ascii	"usage: $0 file...\012\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ 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]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-16]
	cmp	r3, #1
	bgt	.L38
	ldr	r3, .L42
	ldr	r3, [r3]
	mov	r2, #18
	mov	r1, #1
	ldr	r0, .L42+4
	bl	fwrite
	mov	r3, #100
	b	.L39
.L38:
	mov	r3, #1
	str	r3, [fp, #-8]
	b	.L40
.L41:
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-20]
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r0, r3
	bl	part1
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L40:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	cmp	r2, r3
	blt	.L41
	mov	r3, #0
.L39:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L43:
	.align	2
.L42:
	.word	stderr
	.word	.LC14
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
