	.file	"489968.c"
	.intel_syntax noprefix
	.text
	.globl	solutionGenerator
	.type	solutionGenerator, @function
solutionGenerator:
.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	edi, 4
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	BYTE PTR [rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	BYTE PTR 1[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	BYTE PTR 2[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	BYTE PTR 3[rax], 0
	mov	DWORD PTR -16[rbp], 0
	jmp	.L2
.L6:
	call	rand@PLT
	mov	edx, eax
	movsx	rax, edx
	imul	rax, rax, 715827883
	shr	rax, 32
	mov	esi, edx
	sar	esi, 31
	mov	ecx, eax
	sub	ecx, esi
	mov	eax, ecx
	add	eax, eax
	add	eax, ecx
	add	eax, eax
	sub	edx, eax
	mov	ecx, edx
	mov	eax, ecx
	add	eax, 1
	mov	BYTE PTR -17[rbp], al
	mov	BYTE PTR -18[rbp], 0
	mov	DWORD PTR -12[rbp], 0
	jmp	.L3
.L5:
	mov	rdx, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	movzx	eax, BYTE PTR [rdx+rax]
	cmp	BYTE PTR -17[rbp], al
	jne	.L4
	mov	BYTE PTR -18[rbp], 1
.L4:
	add	DWORD PTR -12[rbp], 1
.L3:
	cmp	DWORD PTR -12[rbp], 3
	jle	.L5
	cmp	BYTE PTR -18[rbp], 0
	jne	.L6
	mov	rdx, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	movzx	ecx, BYTE PTR -17[rbp]
	mov	BYTE PTR [rdx+rax], cl
	add	DWORD PTR -16[rbp], 1
.L2:
	cmp	DWORD PTR -16[rbp], 3
	jle	.L6
	mov	rax, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	solutionGenerator, .-solutionGenerator
	.globl	check
	.type	check, @function
check:
.LFB7:
	.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 -32[rbp], rsi
	mov	QWORD PTR -40[rbp], rdx
	mov	rax, QWORD PTR -24[rbp]
	mov	BYTE PTR [rax], 0
	mov	rax, QWORD PTR -24[rbp]
	mov	BYTE PTR 1[rax], 0
	mov	DWORD PTR -12[rbp], 0
	jmp	.L9
.L11:
	mov	rdx, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	movzx	ecx, BYTE PTR [rdx+rax]
	mov	rdx, QWORD PTR -40[rbp]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	movzx	eax, BYTE PTR [rdx+rax]
	cmp	cl, al
	jne	.L10
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	BYTE PTR [rax], dl
.L10:
	add	DWORD PTR -12[rbp], 1
.L9:
	cmp	DWORD PTR -12[rbp], 3
	jle	.L11
	mov	DWORD PTR -8[rbp], 0
	jmp	.L12
.L17:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L13
.L16:
	mov	eax, DWORD PTR -8[rbp]
	cmp	eax, DWORD PTR -4[rbp]
	je	.L18
	mov	rdx, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	movzx	ecx, BYTE PTR [rdx+rax]
	mov	rdx, QWORD PTR -40[rbp]
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	movzx	eax, BYTE PTR [rdx+rax]
	cmp	cl, al
	jne	.L15
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR 1[rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	BYTE PTR 1[rax], dl
	jmp	.L15
.L18:
	nop
.L15:
	add	DWORD PTR -4[rbp], 1
.L13:
	cmp	DWORD PTR -4[rbp], 3
	jle	.L16
	add	DWORD PTR -8[rbp], 1
.L12:
	cmp	DWORD PTR -8[rbp], 3
	jle	.L17
	nop
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	check, .-check
	.section	.rodata
.LC0:
	.string	"-- Mastermind Game--"
.LC1:
	.string	"You have %d attempts left: "
.LC2:
	.string	"%d %d %d %d"
.LC3:
	.string	"c: %d, s: %d\n"
	.align 8
.LC4:
	.string	"You won the game!\nYou had %d attempts left.\n"
	.align 8
.LC5:
	.string	"You lost the game\nThe answer was %d %d %d %d.\n"
	.text
	.globl	main
	.type	main, @function
main:
.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, 48
	mov	edi, 0
	mov	eax, 0
	call	time@PLT
	mov	edi, eax
	call	srand@PLT
	mov	eax, 0
	call	solutionGenerator
	mov	QWORD PTR -32[rbp], rax
	mov	edi, 8
	call	malloc@PLT
	mov	QWORD PTR -24[rbp], rax
	mov	edi, 2
	call	malloc@PLT
	mov	QWORD PTR -16[rbp], rax
	lea	rdi, .LC0[rip]
	call	puts@PLT
	mov	QWORD PTR -40[rbp], 8
	mov	DWORD PTR -48[rbp], 1
.L23:
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, 3[rax]
	mov	rax, QWORD PTR -24[rbp]
	lea	rcx, 2[rax]
	mov	rax, QWORD PTR -24[rbp]
	lea	rdx, 1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	r8, rsi
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	rdx, QWORD PTR -24[rbp]
	mov	rcx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -16[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	check
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR 1[rax]
	movzx	edx, al
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	movzx	eax, al
	mov	esi, eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -44[rbp], 0
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 4
	sete	al
	movzx	eax, al
	mov	DWORD PTR -44[rbp], eax
	cmp	DWORD PTR -44[rbp], 0
	jne	.L27
	sub	QWORD PTR -40[rbp], 1
	cmp	QWORD PTR -40[rbp], 0
	jne	.L23
	mov	DWORD PTR -48[rbp], 0
	jmp	.L21
.L27:
	nop
.L21:
	cmp	DWORD PTR -48[rbp], 0
	je	.L24
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L25
.L24:
	mov	rax, QWORD PTR -32[rbp]
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 3
	movzx	eax, BYTE PTR [rax]
	movzx	esi, al
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 2
	movzx	eax, BYTE PTR [rax]
	movzx	ecx, al
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 1
	movzx	eax, BYTE PTR [rax]
	movzx	edx, al
	mov	rax, QWORD PTR -8[rbp]
	movzx	eax, BYTE PTR [rax]
	movzx	eax, al
	mov	r8d, esi
	mov	esi, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
.L25:
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.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	"489968.c"
	.text
	.align	2
	.global	solutionGenerator
	.syntax unified
	.arm
	.fpu softvfp
	.type	solutionGenerator, %function
solutionGenerator:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	mov	r0, #4
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	strb	r2, [r3]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	strb	r2, [r3, #1]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	strb	r2, [r3, #2]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	strb	r2, [r3, #3]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L2
.L6:
	bl	rand
	mov	r1, r0
	ldr	r3, .L8
	smull	r0, r2, r3, r1
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #1
	sub	r2, r1, r3
	and	r3, r2, #255
	add	r3, r3, #1
	strb	r3, [fp, #-17]
	mov	r3, #0
	strb	r3, [fp, #-18]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L3
.L5:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-12]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	ldrb	r2, [fp, #-17]	@ zero_extendqisi2
	cmp	r2, r3
	bne	.L4
	mov	r3, #1
	strb	r3, [fp, #-18]
.L4:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L3:
	ldr	r3, [fp, #-12]
	cmp	r3, #3
	ble	.L5
	ldrb	r3, [fp, #-18]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L6
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	ldrb	r2, [fp, #-17]
	strb	r2, [r3]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L2:
	ldr	r3, [fp, #-16]
	cmp	r3, #3
	ble	.L6
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L9:
	.align	2
.L8:
	.word	715827883
	.size	solutionGenerator, .-solutionGenerator
	.align	2
	.global	check
	.syntax unified
	.arm
	.fpu softvfp
	.type	check, %function
check:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #36
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	ldr	r3, [fp, #-24]
	mov	r2, #0
	strb	r2, [r3]
	ldr	r3, [fp, #-24]
	mov	r2, #0
	strb	r2, [r3, #1]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L11
.L13:
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	ldrb	r2, [r3]	@ zero_extendqisi2
	ldr	r1, [fp, #-32]
	ldr	r3, [fp, #-16]
	add	r3, r1, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r2, r3
	bne	.L12
	ldr	r3, [fp, #-24]
	ldrb	r3, [r3]	@ zero_extendqisi2
	add	r3, r3, #1
	and	r2, r3, #255
	ldr	r3, [fp, #-24]
	strb	r2, [r3]
.L12:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L11:
	ldr	r3, [fp, #-16]
	cmp	r3, #3
	ble	.L13
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L14
.L19:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L15
.L18:
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-8]
	cmp	r2, r3
	beq	.L20
	ldr	r2, [fp, #-28]
	ldr	r3, [fp, #-12]
	add	r3, r2, r3
	ldrb	r2, [r3]	@ zero_extendqisi2
	ldr	r1, [fp, #-32]
	ldr	r3, [fp, #-8]
	add	r3, r1, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r2, r3
	bne	.L17
	ldr	r3, [fp, #-24]
	ldrb	r3, [r3, #1]	@ zero_extendqisi2
	add	r3, r3, #1
	and	r2, r3, #255
	ldr	r3, [fp, #-24]
	strb	r2, [r3, #1]
	b	.L17
.L20:
	nop
.L17:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L15:
	ldr	r3, [fp, #-8]
	cmp	r3, #3
	ble	.L18
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L14:
	ldr	r3, [fp, #-12]
	cmp	r3, #3
	ble	.L19
	nop
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	check, .-check
	.section	.rodata
	.align	2
.LC0:
	.ascii	"-- Mastermind Game--\000"
	.align	2
.LC1:
	.ascii	"You have %d attempts left: \000"
	.align	2
.LC2:
	.ascii	"%d %d %d %d\000"
	.align	2
.LC3:
	.ascii	"c: %d, s: %d\012\000"
	.align	2
.LC4:
	.ascii	"You won the game!\012You had %d attempts left.\012\000"
	.align	2
.LC5:
	.ascii	"You lost the game\012The answer was %d %d %d %d.\012"
	.ascii	"\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	mov	r0, #0
	bl	time
	mov	r3, r0
	mov	r0, r3
	bl	srand
	bl	solutionGenerator
	str	r0, [fp, #-24]
	mov	r0, #4
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-20]
	mov	r0, #2
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-16]
	ldr	r0, .L30
	bl	puts
	mov	r3, #8
	str	r3, [fp, #-32]
	mov	r3, #1
	str	r3, [fp, #-28]
.L25:
	ldr	r1, [fp, #-32]
	ldr	r0, .L30+4
	bl	printf
	ldr	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	add	r2, r3, #1
	ldr	r3, [fp, #-20]
	add	r0, r3, #2
	ldr	r3, [fp, #-20]
	add	r3, r3, #3
	str	r3, [sp]
	mov	r3, r0
	ldr	r0, .L30+8
	bl	__isoc99_scanf
	ldr	r2, [fp, #-20]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-16]
	bl	check
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3, #1]	@ zero_extendqisi2
	mov	r2, r3
	ldr	r0, .L30+12
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #4
	moveq	r3, #1
	movne	r3, #0
	and	r3, r3, #255
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L29
	ldr	r3, [fp, #-32]
	sub	r3, r3, #1
	str	r3, [fp, #-32]
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bne	.L25
	mov	r3, #0
	str	r3, [fp, #-28]
	b	.L23
.L29:
	nop
.L23:
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	beq	.L26
	ldr	r1, [fp, #-32]
	ldr	r0, .L30+16
	bl	printf
	b	.L27
.L26:
	ldr	r3, [fp, #-24]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r2, r3
	ldr	r3, [fp, #-8]
	add	r3, r3, #2
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r0, r3
	ldr	r3, [fp, #-8]
	add	r3, r3, #3
	ldrb	r3, [r3]	@ zero_extendqisi2
	str	r3, [sp]
	mov	r3, r0
	ldr	r0, .L30+20
	bl	printf
.L27:
	ldr	r0, [fp, #-16]
	bl	free
	ldr	r0, [fp, #-20]
	bl	free
	ldr	r0, [fp, #-24]
	bl	free
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L31:
	.align	2
.L30:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
