	.file	"43886994.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"r"
.LC1:
	.string	","
	.text
	.globl	init
	.type	init, @function
init:
.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, 1072
	mov	QWORD PTR -1064[rbp], rdi
	mov	QWORD PTR -1072[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -1072[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -1048[rbp], rax
	mov	rdx, QWORD PTR -1048[rbp]
	lea	rax, -1040[rbp]
	mov	esi, 1024
	mov	rdi, rax
	call	fgets@PLT
	mov	rax, QWORD PTR -1048[rbp]
	mov	rdi, rax
	call	fclose@PLT
	lea	rax, -1040[rbp]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	call	strtok@PLT
	mov	QWORD PTR -1056[rbp], rax
	jmp	.L2
.L3:
	mov	rax, QWORD PTR -1056[rbp]
	mov	edx, 10
	mov	esi, 0
	mov	rdi, rax
	call	strtol@PLT
	mov	rdx, rax
	lea	rcx, 0[0+rdx*8]
	mov	rdx, QWORD PTR -1064[rbp]
	add	rdx, rcx
	mov	rdx, QWORD PTR [rdx]
	lea	rcx, 0[0+rax*8]
	mov	rax, QWORD PTR -1064[rbp]
	add	rax, rcx
	add	rdx, 1
	mov	QWORD PTR [rax], rdx
	lea	rsi, .LC1[rip]
	mov	edi, 0
	call	strtok@PLT
	mov	QWORD PTR -1056[rbp], rax
.L2:
	cmp	QWORD PTR -1056[rbp], 0
	jne	.L3
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L4
	call	__stack_chk_fail@PLT
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	init, .-init
	.globl	step
	.type	step, @function
step:
.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, 112
	mov	QWORD PTR -104[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -80[rbp], 0
	mov	QWORD PTR -72[rbp], 0
	mov	QWORD PTR -64[rbp], 0
	mov	QWORD PTR -56[rbp], 0
	mov	QWORD PTR -48[rbp], 0
	mov	QWORD PTR -40[rbp], 0
	mov	QWORD PTR -32[rbp], 0
	mov	QWORD PTR -24[rbp], 0
	mov	QWORD PTR -16[rbp], 0
	mov	rax, QWORD PTR -104[rbp]
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR -88[rbp], rax
	mov	rax, QWORD PTR -88[rbp]
	mov	QWORD PTR -16[rbp], rax
	mov	rax, QWORD PTR -88[rbp]
	mov	QWORD PTR -32[rbp], rax
	mov	DWORD PTR -92[rbp], 0
	jmp	.L6
.L7:
	mov	eax, DWORD PTR -92[rbp]
	cdqe
	mov	rdx, QWORD PTR -80[rbp+rax*8]
	mov	eax, DWORD PTR -92[rbp]
	cdqe
	add	rax, 1
	lea	rcx, 0[0+rax*8]
	mov	rax, QWORD PTR -104[rbp]
	add	rax, rcx
	mov	rax, QWORD PTR [rax]
	add	rdx, rax
	mov	eax, DWORD PTR -92[rbp]
	cdqe
	mov	QWORD PTR -80[rbp+rax*8], rdx
	add	DWORD PTR -92[rbp], 1
.L6:
	cmp	DWORD PTR -92[rbp], 7
	jle	.L7
	lea	rcx, -80[rbp]
	mov	rax, QWORD PTR -104[rbp]
	mov	edx, 72
	mov	rsi, rcx
	mov	rdi, rax
	call	memcpy@PLT
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L8
	call	__stack_chk_fail@PLT
.L8:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	step, .-step
	.globl	count_fish
	.type	count_fish, @function
count_fish:
.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 -24[rbp], rdi
	mov	QWORD PTR -8[rbp], 0
	mov	DWORD PTR -12[rbp], 0
	jmp	.L10
.L11:
	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]
	add	QWORD PTR -8[rbp], rax
	add	DWORD PTR -12[rbp], 1
.L10:
	cmp	DWORD PTR -12[rbp], 8
	jle	.L11
	mov	rax, QWORD PTR -8[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	count_fish, .-count_fish
	.section	.rodata
.LC2:
	.string	"input.txt"
.LC3:
	.string	"Part 1: %lld\n"
.LC4:
	.string	"Part 2: %lld\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, 96
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -80[rbp], 0
	mov	QWORD PTR -72[rbp], 0
	mov	QWORD PTR -64[rbp], 0
	mov	QWORD PTR -56[rbp], 0
	mov	QWORD PTR -48[rbp], 0
	mov	QWORD PTR -40[rbp], 0
	mov	QWORD PTR -32[rbp], 0
	mov	QWORD PTR -24[rbp], 0
	mov	QWORD PTR -16[rbp], 0
	lea	rax, -80[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	call	init
	mov	DWORD PTR -88[rbp], 0
	jmp	.L14
.L15:
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	step
	add	DWORD PTR -88[rbp], 1
.L14:
	cmp	DWORD PTR -88[rbp], 79
	jle	.L15
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	count_fish
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -84[rbp], 0
	jmp	.L16
.L17:
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	step
	add	DWORD PTR -84[rbp], 1
.L16:
	cmp	DWORD PTR -84[rbp], 175
	jle	.L17
	lea	rax, -80[rbp]
	mov	rdi, rax
	call	count_fish
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L19
	call	__stack_chk_fail@PLT
.L19:
	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	"43886994.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"r\000"
	.align	2
.LC1:
	.ascii	",\000"
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	init
	.syntax unified
	.arm
	.fpu softvfp
	.type	init, %function
init:
	@ args = 0, pretend = 0, frame = 1048
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #1040
	sub	sp, sp, #8
	str	r0, [fp, #-1056]
	str	r1, [fp, #-1060]
	ldr	r3, .L5
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	ldr	r1, .L5+4
	ldr	r0, [fp, #-1060]
	bl	fopen
	str	r0, [fp, #-1044]
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [fp, #-1044]
	mov	r1, #1024
	mov	r0, r3
	bl	fgets
	ldr	r0, [fp, #-1044]
	bl	fclose
	sub	r3, fp, #1024
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L5+8
	mov	r0, r3
	bl	strtok
	str	r0, [fp, #-1048]
	b	.L2
.L3:
	mov	r2, #10
	mov	r1, #0
	ldr	r0, [fp, #-1048]
	bl	strtol
	mov	r1, r0
	mov	r3, r1
	lsl	r3, r3, #3
	ldr	r2, [fp, #-1056]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	lsl	r1, r1, #3
	ldr	r0, [fp, #-1056]
	add	r1, r0, r1
	adds	r4, r2, #1
	adc	r5, r3, #0
	stm	r1, {r4-r5}
	ldr	r1, .L5+8
	mov	r0, #0
	bl	strtok
	str	r0, [fp, #-1048]
.L2:
	ldr	r3, [fp, #-1048]
	cmp	r3, #0
	bne	.L3
	nop
	ldr	r3, .L5
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L4
	bl	__stack_chk_fail
.L4:
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L6:
	.align	2
.L5:
	.word	.LC2
	.word	.LC0
	.word	.LC1
	.size	init, .-init
	.section	.rodata
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	step
	.syntax unified
	.arm
	.fpu softvfp
	.type	step, %function
step:
	@ args = 0, pretend = 0, frame = 104
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #104
	str	r0, [fp, #-112]
	ldr	r3, .L11
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #92
	mov	r2, #72
	mov	r1, #0
	mov	r0, r3
	bl	memset
	ldr	r3, [fp, #-112]
	ldmia	r3, {r2-r3}
	str	r2, [fp, #-100]
	str	r3, [fp, #-96]
	sub	r3, fp, #100
	ldmia	r3, {r2-r3}
	str	r2, [fp, #-28]
	str	r3, [fp, #-24]
	sub	r3, fp, #100
	ldmia	r3, {r2-r3}
	str	r2, [fp, #-44]
	str	r3, [fp, #-40]
	mov	r3, #0
	str	r3, [fp, #-104]
	b	.L8
.L9:
	ldr	r3, [fp, #-104]
	lsl	r3, r3, #3
	sub	r2, fp, #12
	add	r3, r2, r3
	sub	r3, r3, #80
	ldmia	r3, {r0-r1}
	ldr	r3, [fp, #-104]
	add	r3, r3, #1
	lsl	r3, r3, #3
	ldr	r2, [fp, #-112]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	adds	r4, r0, r2
	adc	r5, r1, r3
	ldr	r3, [fp, #-104]
	lsl	r3, r3, #3
	sub	r2, fp, #12
	add	r3, r2, r3
	sub	r3, r3, #80
	stm	r3, {r4-r5}
	ldr	r3, [fp, #-104]
	add	r3, r3, #1
	str	r3, [fp, #-104]
.L8:
	ldr	r3, [fp, #-104]
	cmp	r3, #7
	ble	.L9
	sub	r3, fp, #92
	mov	r2, #72
	mov	r1, r3
	ldr	r0, [fp, #-112]
	bl	memcpy
	nop
	ldr	r3, .L11
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L10
	bl	__stack_chk_fail
.L10:
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L12:
	.align	2
.L11:
	.word	.LC3
	.size	step, .-step
	.align	2
	.global	count_fish
	.syntax unified
	.arm
	.fpu softvfp
	.type	count_fish, %function
count_fish:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	push	{r4, r5, fp}
	add	fp, sp, #8
	sub	sp, sp, #28
	str	r0, [fp, #-32]
	mov	r2, #0
	mov	r3, #0
	str	r2, [fp, #-20]
	str	r3, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L14
.L15:
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldmia	r3, {r2-r3}
	sub	r1, fp, #20
	ldmia	r1, {r0-r1}
	adds	r4, r0, r2
	adc	r5, r1, r3
	str	r4, [fp, #-20]
	str	r5, [fp, #-16]
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L14:
	ldr	r3, [fp, #-24]
	cmp	r3, #8
	ble	.L15
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	mov	r0, r2
	mov	r1, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, r5, fp}
	bx	lr
	.size	count_fish, .-count_fish
	.section	.rodata
	.align	2
.LC4:
	.ascii	"input.txt\000"
	.align	2
.LC5:
	.ascii	"Part 1: %lld\012\000"
	.align	2
.LC6:
	.ascii	"Part 2: %lld\012\000"
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 88
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #88
	ldr	r3, .L24
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #84
	mov	r2, #72
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #84
	ldr	r1, .L24+4
	mov	r0, r3
	bl	init
	mov	r3, #0
	str	r3, [fp, #-92]
	b	.L18
.L19:
	sub	r3, fp, #84
	mov	r0, r3
	bl	step
	ldr	r3, [fp, #-92]
	add	r3, r3, #1
	str	r3, [fp, #-92]
.L18:
	ldr	r3, [fp, #-92]
	cmp	r3, #79
	ble	.L19
	sub	r3, fp, #84
	mov	r0, r3
	bl	count_fish
	mov	r2, r0
	mov	r3, r1
	ldr	r0, .L24+8
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-88]
	b	.L20
.L21:
	sub	r3, fp, #84
	mov	r0, r3
	bl	step
	ldr	r3, [fp, #-88]
	add	r3, r3, #1
	str	r3, [fp, #-88]
.L20:
	ldr	r3, [fp, #-88]
	cmp	r3, #175
	ble	.L21
	sub	r3, fp, #84
	mov	r0, r3
	bl	count_fish
	mov	r2, r0
	mov	r3, r1
	ldr	r0, .L24+12
	bl	printf
	mov	r3, #0
	ldr	r2, .L24
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L23
	bl	__stack_chk_fail
.L23:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L25:
	.align	2
.L24:
	.word	.LC7
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
