	.file	"39797.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"(%%%ds)%%%ds-%%%ds"
	.align 8
.LC1:
	.string	"Enter phone number [(xxx) xxx-xxxx]: "
	.align 8
.LC2:
	.string	"Input invalid. Please try again."
.LC3:
	.string	"%s.%s.%s\n"
	.text
	.globl	main
	.type	main, @function
main:
.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, 352
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	QWORD PTR -317[rbp], 0
	mov	DWORD PTR -309[rbp], 0
	mov	BYTE PTR -305[rbp], 0
	mov	DWORD PTR -340[rbp], 0
	mov	DWORD PTR -344[rbp], 0
	lea	rax, -317[rbp]
	mov	QWORD PTR -304[rbp], rax
	lea	rax, -317[rbp]
	add	rax, 4
	mov	QWORD PTR -296[rbp], rax
	lea	rax, -317[rbp]
	add	rax, 8
	mov	QWORD PTR -288[rbp], rax
	mov	QWORD PTR -280[rbp], 0
	lea	rax, .LC0[rip]
	mov	QWORD PTR -328[rbp], rax
	mov	QWORD PTR -272[rbp], 0
	mov	QWORD PTR -264[rbp], 0
	mov	QWORD PTR -256[rbp], 0
	mov	QWORD PTR -248[rbp], 0
	mov	QWORD PTR -240[rbp], 0
	mov	QWORD PTR -232[rbp], 0
	mov	QWORD PTR -224[rbp], 0
	mov	QWORD PTR -216[rbp], 0
	mov	QWORD PTR -208[rbp], 0
	mov	QWORD PTR -200[rbp], 0
	mov	QWORD PTR -192[rbp], 0
	mov	QWORD PTR -184[rbp], 0
	mov	QWORD PTR -176[rbp], 0
	mov	QWORD PTR -168[rbp], 0
	mov	QWORD PTR -160[rbp], 0
	mov	QWORD PTR -152[rbp], 0
	mov	QWORD PTR -144[rbp], 0
	mov	QWORD PTR -136[rbp], 0
	mov	QWORD PTR -128[rbp], 0
	mov	QWORD PTR -120[rbp], 0
	mov	QWORD PTR -112[rbp], 0
	mov	QWORD PTR -104[rbp], 0
	mov	QWORD PTR -96[rbp], 0
	mov	QWORD PTR -88[rbp], 0
	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	rsi, QWORD PTR -328[rbp]
	lea	rax, -272[rbp]
	mov	r8d, 4
	mov	ecx, 3
	mov	edx, 3
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L2
.L12:
	lea	rax, -317[rbp]
	lea	rcx, 8[rax]
	lea	rax, -317[rbp]
	lea	rdx, 4[rax]
	lea	rsi, -317[rbp]
	lea	rax, -272[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	DWORD PTR -340[rbp], eax
	cmp	DWORD PTR -340[rbp], 2
	jg	.L3
	lea	rdi, .LC2[rip]
	call	puts@PLT
	mov	BYTE PTR -345[rbp], 0
	jmp	.L4
.L6:
	nop
.L4:
	call	getchar@PLT
	mov	BYTE PTR -345[rbp], al
	cmp	BYTE PTR -345[rbp], 10
	je	.L2
	cmp	BYTE PTR -345[rbp], -1
	jne	.L6
	jmp	.L2
.L3:
	call	getchar@PLT
	mov	DWORD PTR -344[rbp], 1
	lea	rax, -304[rbp]
	mov	QWORD PTR -336[rbp], rax
	jmp	.L7
.L11:
	cmp	DWORD PTR -344[rbp], 0
	je	.L8
	mov	rax, QWORD PTR -336[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	IsNumericLiteral
	test	eax, eax
	je	.L8
	mov	eax, 1
	jmp	.L9
.L8:
	mov	eax, 0
.L9:
	mov	DWORD PTR -344[rbp], eax
	cmp	DWORD PTR -344[rbp], 0
	jne	.L10
	lea	rdi, .LC2[rip]
	call	puts@PLT
	jmp	.L2
.L10:
	add	QWORD PTR -336[rbp], 8
.L7:
	mov	rax, QWORD PTR -336[rbp]
	mov	rax, QWORD PTR [rax]
	test	rax, rax
	jne	.L11
.L2:
	cmp	DWORD PTR -344[rbp], 0
	je	.L12
	lea	rax, -317[rbp]
	lea	rcx, 8[rax]
	lea	rax, -317[rbp]
	lea	rdx, 4[rax]
	lea	rax, -317[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	call	getchar@PLT
	mov	eax, 0
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L14
	call	__stack_chk_fail@PLT
.L14:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.globl	IsNumericLiteral
	.type	IsNumericLiteral, @function
IsNumericLiteral:
.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, 32
	mov	QWORD PTR -24[rbp], rdi
	cmp	QWORD PTR -24[rbp], 0
	jne	.L16
	mov	eax, 0
	jmp	.L17
.L16:
	mov	BYTE PTR -1[rbp], 0
	jmp	.L18
.L20:
	call	__ctype_b_loc@PLT
	mov	rdx, QWORD PTR [rax]
	movsx	rax, BYTE PTR -1[rbp]
	add	rax, rax
	add	rax, rdx
	movzx	eax, WORD PTR [rax]
	movzx	eax, ax
	and	eax, 2048
	test	eax, eax
	jne	.L19
	mov	eax, 0
	jmp	.L17
.L19:
	add	QWORD PTR -24[rbp], 1
.L18:
	mov	rax, QWORD PTR -24[rbp]
	movzx	eax, BYTE PTR [rax]
	mov	BYTE PTR -1[rbp], al
	cmp	BYTE PTR -1[rbp], 0
	jne	.L20
	mov	eax, 1
.L17:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	IsNumericLiteral, .-IsNumericLiteral
	.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	"39797.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"(%%%ds)%%%ds-%%%ds\000"
	.align	2
.LC1:
	.ascii	"Enter phone number [(xxx) xxx-xxxx]: \000"
	.align	2
.LC2:
	.ascii	"Input invalid. Please try again.\000"
	.align	2
.LC3:
	.ascii	"%s.%s.%s\012\000"
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 312
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #320
	ldr	r3, .L14
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #296
	mov	r2, #0
	str	r2, [r3]
	str	r2, [r3, #4]
	str	r2, [r3, #8]
	strb	r2, [r3, #12]
	mov	r3, #0
	str	r3, [fp, #-304]
	mov	r3, #0
	str	r3, [fp, #-312]
	sub	r3, fp, #296
	str	r3, [fp, #-280]
	sub	r3, fp, #296
	add	r3, r3, #4
	str	r3, [fp, #-276]
	sub	r3, fp, #296
	add	r3, r3, #8
	str	r3, [fp, #-272]
	mov	r3, #0
	str	r3, [fp, #-268]
	ldr	r3, .L14+4
	str	r3, [fp, #-300]
	mov	r3, #0
	str	r3, [fp, #-264]
	sub	r3, fp, #260
	mov	r2, #252
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r0, fp, #264
	mov	r3, #4
	str	r3, [sp]
	mov	r3, #3
	mov	r2, #3
	ldr	r1, [fp, #-300]
	bl	sprintf
	ldr	r0, .L14+8
	bl	printf
	b	.L2
.L11:
	sub	r3, fp, #296
	add	ip, r3, #8
	sub	r3, fp, #296
	add	r2, r3, #4
	sub	r1, fp, #296
	sub	r0, fp, #264
	mov	r3, ip
	bl	__isoc99_scanf
	str	r0, [fp, #-304]
	ldr	r3, [fp, #-304]
	cmp	r3, #2
	bgt	.L3
	ldr	r0, .L14+12
	bl	puts
	mov	r3, #0
	strb	r3, [fp, #-313]
	b	.L4
.L5:
	nop
.L4:
	bl	getchar
	mov	r3, r0
	strb	r3, [fp, #-313]
	ldrb	r3, [fp, #-313]	@ zero_extendqisi2
	cmp	r3, #10
	bne	.L5
	b	.L2
.L3:
	bl	getchar
	mov	r3, #1
	str	r3, [fp, #-312]
	sub	r3, fp, #280
	str	r3, [fp, #-308]
	b	.L6
.L10:
	ldr	r3, [fp, #-312]
	cmp	r3, #0
	beq	.L7
	ldr	r3, [fp, #-308]
	ldr	r3, [r3]
	mov	r0, r3
	bl	IsNumericLiteral
	mov	r3, r0
	cmp	r3, #0
	beq	.L7
	mov	r3, #1
	b	.L8
.L7:
	mov	r3, #0
.L8:
	str	r3, [fp, #-312]
	ldr	r3, [fp, #-312]
	cmp	r3, #0
	bne	.L9
	ldr	r0, .L14+12
	bl	puts
	b	.L2
.L9:
	ldr	r3, [fp, #-308]
	add	r3, r3, #4
	str	r3, [fp, #-308]
.L6:
	ldr	r3, [fp, #-308]
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L10
.L2:
	ldr	r3, [fp, #-312]
	cmp	r3, #0
	beq	.L11
	sub	r3, fp, #296
	add	r0, r3, #8
	sub	r3, fp, #296
	add	r2, r3, #4
	sub	r1, fp, #296
	mov	r3, r0
	ldr	r0, .L14+16
	bl	printf
	bl	getchar
	mov	r3, #0
	ldr	r2, .L14
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L13
	bl	__stack_chk_fail
.L13:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L15:
	.align	2
.L14:
	.word	.LC4
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.size	main, .-main
	.align	2
	.global	IsNumericLiteral
	.syntax unified
	.arm
	.fpu softvfp
	.type	IsNumericLiteral, %function
IsNumericLiteral:
	@ 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	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L17
	mov	r3, #0
	b	.L18
.L17:
	mov	r3, #0
	strb	r3, [fp, #-5]
	b	.L19
.L21:
	bl	__ctype_b_loc
	mov	r3, r0
	ldr	r2, [r3]
	ldrb	r3, [fp, #-5]	@ zero_extendqisi2
	lsl	r3, r3, #1
	add	r3, r2, r3
	ldrh	r3, [r3]
	and	r3, r3, #2048
	cmp	r3, #0
	bne	.L20
	mov	r3, #0
	b	.L18
.L20:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L19:
	ldr	r3, [fp, #-16]
	ldrb	r3, [r3]
	strb	r3, [fp, #-5]
	ldrb	r3, [fp, #-5]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L21
	mov	r3, #1
.L18:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	IsNumericLiteral, .-IsNumericLiteral
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
