	.file	"449641.c"
	.intel_syntax noprefix
	.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, 64
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	jmp	.L2
.L8:
	lea	rax, -48[rbp]
	mov	rdi, rax
	call	Trim
	lea	rax, -48[rbp]
	mov	rdi, rax
	call	strlen@PLT
	sub	rax, 1
	movzx	eax, BYTE PTR -48[rbp+rax]
	mov	BYTE PTR -53[rbp], al
	lea	rax, -48[rbp]
	mov	rdi, rax
	call	strlen@PLT
	sub	eax, 2
	mov	DWORD PTR -52[rbp], eax
	jmp	.L3
.L5:
	sub	DWORD PTR -52[rbp], 1
.L3:
	cmp	DWORD PTR -52[rbp], -1
	je	.L4
	mov	eax, DWORD PTR -52[rbp]
	cdqe
	movzx	eax, BYTE PTR -48[rbp+rax]
	cmp	BYTE PTR -53[rbp], al
	jne	.L5
.L4:
	cmp	DWORD PTR -52[rbp], -1
	je	.L6
	mov	eax, DWORD PTR -52[rbp]
	add	eax, 1
	lea	rdx, -48[rbp]
	cdqe
	add	rdx, rax
	lea	rax, -48[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strstr@PLT
	mov	edx, DWORD PTR -52[rbp]
	add	edx, 1
	lea	rcx, -48[rbp]
	movsx	rdx, edx
	add	rdx, rcx
	cmp	rax, rdx
	je	.L6
	mov	eax, DWORD PTR -52[rbp]
	sub	eax, 1
	cdqe
	movzx	edx, BYTE PTR -48[rbp+rax]
	mov	eax, DWORD PTR -52[rbp]
	cdqe
	movzx	eax, BYTE PTR -48[rbp+rax]
	cmp	dl, al
	jne	.L7
	mov	eax, DWORD PTR -52[rbp]
	cdqe
	mov	BYTE PTR -48[rbp+rax], 0
	jmp	.L6
.L7:
	mov	eax, DWORD PTR -52[rbp]
	add	eax, 1
	cdqe
	mov	BYTE PTR -48[rbp+rax], 0
.L6:
	lea	rax, -48[rbp]
	mov	rdi, rax
	call	puts@PLT
.L2:
	mov	rdx, QWORD PTR stdin[rip]
	lea	rax, -48[rbp]
	mov	esi, 32
	mov	rdi, rax
	call	fgets@PLT
	test	rax, rax
	jne	.L8
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L10
	call	__stack_chk_fail@PLT
.L10:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.globl	Trim
	.type	Trim, @function
Trim:
.LFB1:
	.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	rdi, rax
	call	strlen@PLT
	lea	rdx, -1[rax]
	mov	rax, QWORD PTR -8[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	cmp	al, 10
	jne	.L12
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	strlen@PLT
	lea	rdx, -1[rax]
	mov	rax, QWORD PTR -8[rbp]
	add	rax, rdx
	mov	BYTE PTR [rax], 0
.L12:
	mov	rax, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	Trim, .-Trim
	.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	"449641.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #48
	ldr	r3, .L11
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	b	.L2
.L8:
	sub	r3, fp, #40
	mov	r0, r3
	bl	Trim
	sub	r3, fp, #40
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	sub	r3, r3, #1
	sub	r2, fp, #4
	add	r3, r2, r3
	ldrb	r3, [r3, #-36]
	strb	r3, [fp, #-45]
	sub	r3, fp, #40
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	sub	r3, r3, #2
	str	r3, [fp, #-44]
	b	.L3
.L5:
	ldr	r3, [fp, #-44]
	sub	r3, r3, #1
	str	r3, [fp, #-44]
.L3:
	ldr	r3, [fp, #-44]
	cmn	r3, #1
	beq	.L4
	sub	r2, fp, #40
	ldr	r3, [fp, #-44]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	ldrb	r2, [fp, #-45]	@ zero_extendqisi2
	cmp	r2, r3
	bne	.L5
.L4:
	ldr	r3, [fp, #-44]
	cmn	r3, #1
	beq	.L6
	ldr	r3, [fp, #-44]
	add	r3, r3, #1
	sub	r2, fp, #40
	add	r2, r2, r3
	sub	r3, fp, #40
	mov	r1, r2
	mov	r0, r3
	bl	strstr
	mov	r1, r0
	ldr	r3, [fp, #-44]
	add	r3, r3, #1
	sub	r2, fp, #40
	add	r3, r2, r3
	cmp	r1, r3
	beq	.L6
	ldr	r3, [fp, #-44]
	sub	r3, r3, #1
	sub	r2, fp, #4
	add	r3, r2, r3
	ldrb	r2, [r3, #-36]	@ zero_extendqisi2
	sub	r1, fp, #40
	ldr	r3, [fp, #-44]
	add	r3, r1, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r2, r3
	bne	.L7
	sub	r2, fp, #40
	ldr	r3, [fp, #-44]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
	b	.L6
.L7:
	ldr	r3, [fp, #-44]
	add	r3, r3, #1
	sub	r2, fp, #4
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3, #-36]
.L6:
	sub	r3, fp, #40
	mov	r0, r3
	bl	puts
.L2:
	ldr	r3, .L11+4
	ldr	r2, [r3]
	sub	r3, fp, #40
	mov	r1, #32
	mov	r0, r3
	bl	fgets
	mov	r3, r0
	cmp	r3, #0
	bne	.L8
	mov	r3, #0
	ldr	r2, .L11
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L10
	bl	__stack_chk_fail
.L10:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L12:
	.align	2
.L11:
	.word	.LC0
	.word	stdin
	.size	main, .-main
	.align	2
	.global	Trim
	.syntax unified
	.arm
	.fpu softvfp
	.type	Trim, %function
Trim:
	@ 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	r0, [fp, #-8]
	bl	strlen
	mov	r3, r0
	sub	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #10
	bne	.L14
	ldr	r0, [fp, #-8]
	bl	strlen
	mov	r3, r0
	sub	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
.L14:
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	Trim, .-Trim
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
