	.file	"82949320.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"\n\nCheck whether a number is Keith or not :"
	.align 8
.LC1:
	.string	"Sample Keith Numbers: 197, 742, 1104,1537..."
	.align 8
.LC2:
	.string	"--------------------------------------------"
.LC3:
	.string	"Input a number : "
.LC4:
	.string	"%d"
.LC5:
	.string	" %d"
.LC6:
	.string	" + "
.LC7:
	.string	" = %d"
	.align 8
.LC8:
	.string	"The given number is a Keith Number."
	.align 8
.LC9:
	.string	"The given number is NOT a Keith Number."
	.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, 80
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -72[rbp], 0
	mov	DWORD PTR -52[rbp], 0
	mov	DWORD PTR -68[rbp], 0
	mov	DWORD PTR -64[rbp], 0
	mov	DWORD PTR -60[rbp], 0
	lea	rdi, .LC0[rip]
	call	puts@PLT
	lea	rdi, .LC1[rip]
	call	puts@PLT
	lea	rdi, .LC2[rip]
	call	puts@PLT
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -72[rbp]
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	eax, DWORD PTR -72[rbp]
	mov	DWORD PTR -52[rbp], eax
	mov	eax, DWORD PTR -52[rbp]
	mov	edi, eax
	call	lenCount
	sub	eax, 1
	mov	DWORD PTR -64[rbp], eax
	jmp	.L2
.L3:
	mov	ecx, DWORD PTR -72[rbp]
	movsx	rax, ecx
	imul	rax, rax, 1717986919
	shr	rax, 32
	sar	eax, 2
	mov	esi, ecx
	sar	esi, 31
	sub	eax, esi
	mov	edx, eax
	mov	eax, edx
	sal	eax, 2
	add	eax, edx
	add	eax, eax
	sub	ecx, eax
	mov	edx, ecx
	mov	eax, DWORD PTR -64[rbp]
	cdqe
	mov	DWORD PTR -48[rbp+rax*4], edx
	mov	eax, DWORD PTR -72[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1717986919
	shr	rdx, 32
	sar	edx, 2
	sar	eax, 31
	mov	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	mov	DWORD PTR -72[rbp], eax
	sub	DWORD PTR -64[rbp], 1
.L2:
	cmp	DWORD PTR -64[rbp], 0
	jns	.L3
	jmp	.L4
.L13:
	mov	DWORD PTR -64[rbp], 0
	jmp	.L5
.L6:
	mov	eax, DWORD PTR -64[rbp]
	cdqe
	mov	eax, DWORD PTR -48[rbp+rax*4]
	add	DWORD PTR -60[rbp], eax
	add	DWORD PTR -64[rbp], 1
.L5:
	mov	eax, DWORD PTR -52[rbp]
	mov	edi, eax
	call	lenCount
	cmp	DWORD PTR -64[rbp], eax
	jl	.L6
	mov	eax, DWORD PTR -60[rbp]
	cmp	eax, DWORD PTR -52[rbp]
	jne	.L7
	mov	DWORD PTR -68[rbp], 1
	mov	DWORD PTR -56[rbp], 1
	jmp	.L8
.L7:
	mov	eax, DWORD PTR -60[rbp]
	cmp	eax, DWORD PTR -52[rbp]
	jle	.L8
	mov	DWORD PTR -68[rbp], 1
	mov	DWORD PTR -56[rbp], 0
.L8:
	mov	DWORD PTR -64[rbp], 0
	jmp	.L9
.L12:
	mov	eax, DWORD PTR -64[rbp]
	cdqe
	mov	eax, DWORD PTR -48[rbp+rax*4]
	mov	esi, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR -52[rbp]
	mov	edi, eax
	call	lenCount
	sub	eax, 1
	cmp	DWORD PTR -64[rbp], eax
	je	.L10
	mov	eax, DWORD PTR -64[rbp]
	add	eax, 1
	cdqe
	mov	edx, DWORD PTR -48[rbp+rax*4]
	mov	eax, DWORD PTR -64[rbp]
	cdqe
	mov	DWORD PTR -48[rbp+rax*4], edx
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L11
.L10:
	mov	eax, DWORD PTR -64[rbp]
	cdqe
	mov	edx, DWORD PTR -60[rbp]
	mov	DWORD PTR -48[rbp+rax*4], edx
	mov	eax, DWORD PTR -64[rbp]
	cdqe
	mov	eax, DWORD PTR -48[rbp+rax*4]
	mov	esi, eax
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	printf@PLT
.L11:
	add	DWORD PTR -64[rbp], 1
.L9:
	mov	eax, DWORD PTR -52[rbp]
	mov	edi, eax
	call	lenCount
	cmp	DWORD PTR -64[rbp], eax
	jl	.L12
	mov	DWORD PTR -60[rbp], 0
	mov	edi, 10
	call	putchar@PLT
.L4:
	cmp	DWORD PTR -68[rbp], 0
	je	.L13
	cmp	DWORD PTR -56[rbp], 1
	jne	.L14
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L15
.L14:
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
.L15:
	mov	eax, 0
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, 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
	.type	lenCount, @function
lenCount:
.LFB1:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -4[rbp], 0
	jmp	.L19
.L20:
	mov	eax, DWORD PTR -20[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1717986919
	shr	rdx, 32
	sar	edx, 2
	sar	eax, 31
	mov	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	mov	DWORD PTR -20[rbp], eax
	add	DWORD PTR -4[rbp], 1
.L19:
	cmp	DWORD PTR -20[rbp], 0
	jg	.L20
	mov	eax, DWORD PTR -4[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	lenCount, .-lenCount
	.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	"82949320.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"\012\012Check whether a number is Keith or not :\000"
	.align	2
.LC1:
	.ascii	"Sample Keith Numbers: 197, 742, 1104,1537...\000"
	.align	2
.LC2:
	.ascii	"--------------------------------------------\000"
	.align	2
.LC3:
	.ascii	"Input a number : \000"
	.align	2
.LC4:
	.ascii	"%d\000"
	.align	2
.LC5:
	.ascii	" %d\000"
	.align	2
.LC6:
	.ascii	" + \000"
	.align	2
.LC7:
	.ascii	" = %d\000"
	.align	2
.LC8:
	.ascii	"The given number is a Keith Number.\000"
	.align	2
.LC9:
	.ascii	"The given number is NOT a Keith Number.\000"
	.align	2
.LC10:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 72
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #72
	ldr	r3, .L18
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-72]
	mov	r3, #0
	str	r3, [fp, #-52]
	mov	r3, #0
	str	r3, [fp, #-68]
	mov	r3, #0
	str	r3, [fp, #-64]
	mov	r3, #0
	str	r3, [fp, #-60]
	ldr	r0, .L18+4
	bl	puts
	ldr	r0, .L18+8
	bl	puts
	ldr	r0, .L18+12
	bl	puts
	ldr	r0, .L18+16
	bl	printf
	sub	r3, fp, #72
	mov	r1, r3
	ldr	r0, .L18+20
	bl	__isoc99_scanf
	ldr	r3, [fp, #-72]
	str	r3, [fp, #-52]
	ldr	r0, [fp, #-52]
	bl	lenCount
	mov	r3, r0
	sub	r3, r3, #1
	str	r3, [fp, #-64]
	b	.L2
.L3:
	ldr	r1, [fp, #-72]
	ldr	r3, .L18+24
	smull	r2, r3, r1, r3
	asr	r2, r3, #2
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	sub	r2, r1, r3
	ldr	r3, [fp, #-64]
	lsl	r3, r3, #2
	sub	r1, fp, #4
	add	r3, r1, r3
	str	r2, [r3, #-44]
	ldr	r3, [fp, #-72]
	ldr	r2, .L18+24
	smull	r1, r2, r3, r2
	asr	r2, r2, #2
	asr	r3, r3, #31
	sub	r3, r2, r3
	str	r3, [fp, #-72]
	ldr	r3, [fp, #-64]
	sub	r3, r3, #1
	str	r3, [fp, #-64]
.L2:
	ldr	r3, [fp, #-64]
	cmp	r3, #0
	bge	.L3
	b	.L4
.L13:
	mov	r3, #0
	str	r3, [fp, #-64]
	b	.L5
.L6:
	ldr	r3, [fp, #-64]
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-44]
	ldr	r2, [fp, #-60]
	add	r3, r2, r3
	str	r3, [fp, #-60]
	ldr	r3, [fp, #-64]
	add	r3, r3, #1
	str	r3, [fp, #-64]
.L5:
	ldr	r0, [fp, #-52]
	bl	lenCount
	mov	r2, r0
	ldr	r3, [fp, #-64]
	cmp	r3, r2
	blt	.L6
	ldr	r2, [fp, #-60]
	ldr	r3, [fp, #-52]
	cmp	r2, r3
	bne	.L7
	mov	r3, #1
	str	r3, [fp, #-68]
	mov	r3, #1
	str	r3, [fp, #-56]
	b	.L8
.L7:
	ldr	r2, [fp, #-60]
	ldr	r3, [fp, #-52]
	cmp	r2, r3
	ble	.L8
	mov	r3, #1
	str	r3, [fp, #-68]
	mov	r3, #0
	str	r3, [fp, #-56]
.L8:
	mov	r3, #0
	str	r3, [fp, #-64]
	b	.L9
.L12:
	ldr	r3, [fp, #-64]
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-44]
	mov	r1, r3
	ldr	r0, .L18+28
	bl	printf
	ldr	r0, [fp, #-52]
	bl	lenCount
	mov	r3, r0
	sub	r3, r3, #1
	ldr	r2, [fp, #-64]
	cmp	r2, r3
	beq	.L10
	ldr	r3, [fp, #-64]
	add	r3, r3, #1
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r2, [r3, #-44]
	ldr	r3, [fp, #-64]
	lsl	r3, r3, #2
	sub	r1, fp, #4
	add	r3, r1, r3
	str	r2, [r3, #-44]
	ldr	r0, .L18+32
	bl	printf
	b	.L11
.L10:
	ldr	r3, [fp, #-64]
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r2, [fp, #-60]
	str	r2, [r3, #-44]
	ldr	r3, [fp, #-64]
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-44]
	mov	r1, r3
	ldr	r0, .L18+36
	bl	printf
.L11:
	ldr	r3, [fp, #-64]
	add	r3, r3, #1
	str	r3, [fp, #-64]
.L9:
	ldr	r0, [fp, #-52]
	bl	lenCount
	mov	r2, r0
	ldr	r3, [fp, #-64]
	cmp	r3, r2
	blt	.L12
	mov	r3, #0
	str	r3, [fp, #-60]
	mov	r0, #10
	bl	putchar
.L4:
	ldr	r3, [fp, #-68]
	cmp	r3, #0
	beq	.L13
	ldr	r3, [fp, #-56]
	cmp	r3, #1
	bne	.L14
	ldr	r0, .L18+40
	bl	printf
	b	.L15
.L14:
	ldr	r0, .L18+44
	bl	printf
.L15:
	mov	r3, #0
	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	.LC10
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	1717986919
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.size	main, .-main
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	lenCount, %function
lenCount:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L21
.L22:
	ldr	r3, [fp, #-16]
	ldr	r2, .L24
	smull	r1, r2, r3, r2
	asr	r2, r2, #2
	asr	r3, r3, #31
	sub	r3, r2, r3
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L21:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bgt	.L22
	ldr	r3, [fp, #-8]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L25:
	.align	2
.L24:
	.word	1717986919
	.size	lenCount, .-lenCount
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
