	.file	"159944.c"
	.intel_syntax noprefix
	.text
	.globl	dumpComputer
	.data
	.type	dumpComputer, @object
	.size	dumpComputer, 1
dumpComputer:
	.byte	1
	.globl	playerBoard
	.bss
	.align 32
	.type	playerBoard, @object
	.size	playerBoard, 480
playerBoard:
	.zero	480
	.globl	computerBoard
	.align 32
	.type	computerBoard, @object
	.size	computerBoard, 480
computerBoard:
	.zero	480
	.globl	compShotBoard
	.align 32
	.type	compShotBoard, @object
	.size	compShotBoard, 480
compShotBoard:
	.zero	480
	.text
	.globl	getRand
	.type	getRand, @function
getRand:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	DWORD PTR -8[rbp], esi
	call	rand@PLT
	mov	edx, DWORD PTR -8[rbp]
	add	edx, 1
	mov	ecx, edx
	sub	ecx, DWORD PTR -4[rbp]
	cdq
	idiv	ecx
	mov	eax, DWORD PTR -4[rbp]
	add	eax, edx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	getRand, .-getRand
	.section	.rodata
.LC0:
	.string	"Give a shot (row, col):"
.LC1:
	.string	"%d%d"
.LC2:
	.string	"Invalid input"
	.text
	.globl	getShot
	.type	getShot, @function
getShot:
.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	eax, edi
	mov	QWORD PTR -32[rbp], rsi
	mov	BYTE PTR -20[rbp], al
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
.L8:
	cmp	BYTE PTR -20[rbp], 0
	je	.L4
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdx, -12[rbp]
	lea	rax, -16[rbp]
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	eax, DWORD PTR -12[rbp]
	test	eax, eax
	jle	.L5
	mov	eax, DWORD PTR -12[rbp]
	cmp	eax, 11
	jg	.L5
	mov	eax, DWORD PTR -16[rbp]
	test	eax, eax
	jle	.L5
	mov	eax, DWORD PTR -16[rbp]
	cmp	eax, 9
	jle	.L6
.L5:
	lea	rdi, .LC2[rip]
	call	puts@PLT
	jmp	.L8
.L4:
	mov	esi, 9
	mov	edi, 1
	call	getRand
	mov	DWORD PTR -16[rbp], eax
	mov	esi, 11
	mov	edi, 1
	call	getRand
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -16[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rcx, edx
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 2
	add	rax, rcx
	lea	rdx, 0[0+rax*4]
	lea	rax, compShotBoard[rip]
	mov	eax, DWORD PTR [rdx+rax]
	test	eax, eax
	jne	.L8
	mov	eax, DWORD PTR -16[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rcx, edx
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 2
	add	rax, rcx
	lea	rdx, 0[0+rax*4]
	lea	rax, compShotBoard[rip]
	mov	DWORD PTR [rdx+rax], 1
.L6:
	mov	eax, DWORD PTR -16[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	test	eax, eax
	je	.L9
	mov	eax, DWORD PTR -16[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	test	eax, eax
	jle	.L10
	mov	eax, DWORD PTR -16[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	mov	ecx, DWORD PTR [rdx+rax*4]
	mov	eax, DWORD PTR -16[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -12[rbp]
	neg	ecx
	cdqe
	mov	DWORD PTR [rdx+rax*4], ecx
.L10:
	mov	eax, DWORD PTR -16[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	neg	eax
	jmp	.L12
.L9:
	mov	eax, 0
.L12:
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	getShot, .-getShot
	.globl	allShipsNotHit
	.type	allShipsNotHit, @function
allShipsNotHit:
.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	DWORD PTR -8[rbp], 1
	jmp	.L15
.L20:
	mov	DWORD PTR -4[rbp], 1
	jmp	.L16
.L19:
	mov	eax, DWORD PTR -8[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -24[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	test	eax, eax
	jle	.L17
	mov	eax, 1
	jmp	.L18
.L17:
	add	DWORD PTR -4[rbp], 1
.L16:
	cmp	DWORD PTR -4[rbp], 11
	jle	.L19
	add	DWORD PTR -8[rbp], 1
.L15:
	cmp	DWORD PTR -8[rbp], 9
	jle	.L20
	mov	eax, 0
.L18:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	allShipsNotHit, .-allShipsNotHit
	.globl	noneLeft
	.type	noneLeft, @function
noneLeft:
.LFB9:
	.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	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -8[rbp], 1
	jmp	.L22
.L27:
	mov	DWORD PTR -4[rbp], 1
	jmp	.L23
.L26:
	mov	eax, DWORD PTR -8[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -32[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	cmp	DWORD PTR -20[rbp], eax
	jne	.L24
	mov	eax, 0
	jmp	.L25
.L24:
	add	DWORD PTR -4[rbp], 1
.L23:
	cmp	DWORD PTR -4[rbp], 11
	jle	.L26
	add	DWORD PTR -8[rbp], 1
.L22:
	cmp	DWORD PTR -8[rbp], 9
	jle	.L27
	mov	eax, 1
.L25:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	noneLeft, .-noneLeft
	.section	.rodata
	.align 8
.LC3:
	.string	"Rows are 1 - 9, Columns are 1 - 11"
	.align 8
.LC4:
	.string	"Orientation is 0 for across, 1 for down"
	.align 8
.LC5:
	.string	"Give starting row, starting column and orientation (3 inputs) for ship of size=%d:"
.LC6:
	.string	"%d %d %d"
.LC7:
	.string	"Invalid Input"
	.align 8
.LC8:
	.string	"Conflicts with ship already placed"
	.text
	.globl	populateBoard
	.type	populateBoard, @function
populateBoard:
.LFB10:
	.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	eax, edi
	mov	QWORD PTR -64[rbp], rsi
	mov	BYTE PTR -52[rbp], al
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	BYTE PTR -52[rbp], 0
	je	.L29
	lea	rdi, .LC3[rip]
	call	puts@PLT
	lea	rdi, .LC4[rip]
	call	puts@PLT
.L29:
	mov	DWORD PTR -28[rbp], 5
	jmp	.L30
.L52:
	cmp	BYTE PTR -52[rbp], 0
	je	.L31
	mov	eax, DWORD PTR -28[rbp]
	mov	esi, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rcx, -32[rbp]
	lea	rdx, -36[rbp]
	lea	rax, -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	jmp	.L32
.L31:
	movzx	eax, BYTE PTR -52[rbp]
	xor	eax, 1
	test	al, al
	je	.L32
	mov	esi, 9
	mov	edi, 1
	call	getRand
	mov	DWORD PTR -40[rbp], eax
	mov	esi, 11
	mov	edi, 1
	call	getRand
	mov	DWORD PTR -36[rbp], eax
	mov	esi, 1
	mov	edi, 0
	call	getRand
	mov	DWORD PTR -32[rbp], eax
.L32:
	mov	eax, DWORD PTR -40[rbp]
	test	eax, eax
	jle	.L33
	mov	eax, DWORD PTR -40[rbp]
	cmp	eax, 9
	jg	.L33
	mov	eax, DWORD PTR -36[rbp]
	test	eax, eax
	jle	.L33
	mov	eax, DWORD PTR -36[rbp]
	cmp	eax, 11
	jg	.L33
	mov	eax, DWORD PTR -32[rbp]
	test	eax, eax
	js	.L33
	mov	eax, DWORD PTR -32[rbp]
	cmp	eax, 1
	jg	.L33
	mov	eax, DWORD PTR -32[rbp]
	test	eax, eax
	jne	.L34
	mov	edx, DWORD PTR -36[rbp]
	mov	eax, DWORD PTR -28[rbp]
	add	eax, edx
	cmp	eax, 12
	jg	.L33
.L34:
	mov	eax, DWORD PTR -32[rbp]
	cmp	eax, 1
	jne	.L35
	mov	edx, DWORD PTR -40[rbp]
	mov	eax, DWORD PTR -28[rbp]
	add	eax, edx
	cmp	eax, 10
	jle	.L35
.L33:
	cmp	BYTE PTR -52[rbp], 0
	je	.L30
	lea	rdi, .LC7[rip]
	call	puts@PLT
	jmp	.L30
.L35:
	mov	BYTE PTR -41[rbp], 1
	mov	eax, DWORD PTR -32[rbp]
	test	eax, eax
	jne	.L37
	mov	DWORD PTR -24[rbp], 0
	jmp	.L38
.L40:
	mov	eax, DWORD PTR -40[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -64[rbp]
	add	rdx, rax
	mov	ecx, DWORD PTR -36[rbp]
	mov	eax, DWORD PTR -24[rbp]
	add	eax, ecx
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	test	eax, eax
	je	.L39
	mov	BYTE PTR -41[rbp], 0
.L39:
	add	DWORD PTR -24[rbp], 1
.L38:
	cmp	DWORD PTR -24[rbp], 0
	jle	.L40
.L37:
	mov	eax, DWORD PTR -32[rbp]
	cmp	eax, 1
	jne	.L41
	mov	DWORD PTR -20[rbp], 0
	jmp	.L42
.L44:
	mov	edx, DWORD PTR -40[rbp]
	mov	eax, DWORD PTR -20[rbp]
	add	eax, edx
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -64[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -36[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	test	eax, eax
	je	.L43
	mov	BYTE PTR -41[rbp], 0
.L43:
	add	DWORD PTR -20[rbp], 1
.L42:
	cmp	DWORD PTR -20[rbp], 0
	jle	.L44
.L41:
	movzx	eax, BYTE PTR -41[rbp]
	xor	eax, 1
	test	al, al
	je	.L45
	cmp	BYTE PTR -52[rbp], 0
	je	.L30
	lea	rdi, .LC8[rip]
	call	puts@PLT
	jmp	.L30
.L45:
	cmp	BYTE PTR -41[rbp], 0
	je	.L30
	mov	eax, DWORD PTR -32[rbp]
	test	eax, eax
	jne	.L46
	mov	eax, DWORD PTR -36[rbp]
	mov	DWORD PTR -16[rbp], eax
	jmp	.L47
.L48:
	mov	eax, DWORD PTR -40[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -64[rbp]
	lea	rcx, [rdx+rax]
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	mov	edx, DWORD PTR -28[rbp]
	mov	DWORD PTR [rcx+rax*4], edx
	add	DWORD PTR -16[rbp], 1
.L47:
	mov	edx, DWORD PTR -36[rbp]
	mov	eax, DWORD PTR -28[rbp]
	add	eax, edx
	cmp	DWORD PTR -16[rbp], eax
	jl	.L48
.L46:
	mov	eax, DWORD PTR -32[rbp]
	cmp	eax, 1
	jne	.L49
	mov	eax, DWORD PTR -40[rbp]
	mov	DWORD PTR -12[rbp], eax
	jmp	.L50
.L51:
	mov	eax, DWORD PTR -12[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -64[rbp]
	lea	rcx, [rdx+rax]
	mov	eax, DWORD PTR -36[rbp]
	cdqe
	mov	edx, DWORD PTR -28[rbp]
	mov	DWORD PTR [rcx+rax*4], edx
	add	DWORD PTR -12[rbp], 1
.L50:
	mov	edx, DWORD PTR -40[rbp]
	mov	eax, DWORD PTR -28[rbp]
	add	eax, edx
	cmp	DWORD PTR -12[rbp], eax
	jl	.L51
.L49:
	sub	DWORD PTR -28[rbp], 1
.L30:
	cmp	DWORD PTR -28[rbp], 0
	jg	.L52
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L53
	call	__stack_chk_fail@PLT
.L53:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	populateBoard, .-populateBoard
	.section	.rodata
.LC9:
	.string	"   Cols"
	.align 8
.LC10:
	.string	"    1  2  3  4  5  6  7  8  9 10 11"
	.align 8
.LC11:
	.string	"     ________________________________"
.LC12:
	.string	"R%d|"
.LC13:
	.string	"%d "
.LC14:
	.string	"|"
	.align 8
.LC15:
	.string	"  __________________________________"
	.text
	.globl	showBoard
	.type	showBoard, @function
showBoard:
.LFB11:
	.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
	lea	rdi, .LC9[rip]
	call	puts@PLT
	lea	rdi, .LC10[rip]
	call	puts@PLT
	lea	rdi, .LC11[rip]
	call	puts@PLT
	mov	DWORD PTR -8[rbp], 1
	jmp	.L55
.L59:
	mov	eax, DWORD PTR -8[rbp]
	mov	esi, eax
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -4[rbp], 1
	jmp	.L56
.L58:
	mov	eax, DWORD PTR -8[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -24[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	test	eax, eax
	js	.L57
	mov	edi, 32
	call	putchar@PLT
.L57:
	mov	eax, DWORD PTR -8[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 4
	mov	rdx, rax
	mov	rax, QWORD PTR -24[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	mov	eax, DWORD PTR [rdx+rax*4]
	mov	esi, eax
	lea	rdi, .LC13[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -4[rbp], 1
.L56:
	cmp	DWORD PTR -4[rbp], 11
	jle	.L58
	lea	rdi, .LC14[rip]
	call	puts@PLT
	add	DWORD PTR -8[rbp], 1
.L55:
	cmp	DWORD PTR -8[rbp], 9
	jle	.L59
	lea	rdi, .LC15[rip]
	call	puts@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	showBoard, .-showBoard
	.section	.rodata
.LC16:
	.string	"Your board is"
.LC17:
	.string	"\n\nComputer board is"
.LC18:
	.string	"HIT on size %d\n"
.LC19:
	.string	"Sunk computer's %d\n"
.LC20:
	.string	"MISS!!"
.LC21:
	.string	"Computer hits! Size=%d\n"
.LC22:
	.string	"Sunk your %d\n"
.LC23:
	.string	"Computer miss!"
.LC24:
	.string	"You win!"
.LC25:
	.string	"You lose."
	.text
	.globl	main
	.type	main, @function
main:
.LFB12:
	.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	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -32[rbp], rsi
	mov	edi, 0
	call	time@PLT
	mov	edi, eax
	call	srand@PLT
	mov	DWORD PTR -12[rbp], 0
	jmp	.L61
.L64:
	mov	DWORD PTR -8[rbp], 0
	jmp	.L62
.L63:
	mov	eax, DWORD PTR -8[rbp]
	movsx	rcx, eax
	mov	eax, DWORD PTR -12[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 2
	add	rax, rcx
	lea	rdx, 0[0+rax*4]
	lea	rax, playerBoard[rip]
	mov	DWORD PTR [rdx+rax], 0
	mov	eax, DWORD PTR -8[rbp]
	movsx	rcx, eax
	mov	eax, DWORD PTR -12[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 2
	add	rax, rcx
	lea	rdx, 0[0+rax*4]
	lea	rax, computerBoard[rip]
	mov	DWORD PTR [rdx+rax], 0
	mov	eax, DWORD PTR -8[rbp]
	movsx	rcx, eax
	mov	eax, DWORD PTR -12[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	sal	rax, 2
	add	rax, rcx
	lea	rdx, 0[0+rax*4]
	lea	rax, compShotBoard[rip]
	mov	DWORD PTR [rdx+rax], 0
	add	DWORD PTR -8[rbp], 1
.L62:
	cmp	DWORD PTR -8[rbp], 10
	jle	.L63
	add	DWORD PTR -12[rbp], 1
.L61:
	cmp	DWORD PTR -12[rbp], 8
	jle	.L64
	lea	rsi, playerBoard[rip]
	mov	edi, 1
	call	populateBoard
	lea	rsi, computerBoard[rip]
	mov	edi, 0
	call	populateBoard
	lea	rdi, .LC16[rip]
	call	puts@PLT
	lea	rdi, playerBoard[rip]
	call	showBoard
	movzx	eax, BYTE PTR dumpComputer[rip]
	test	al, al
	je	.L65
	lea	rdi, .LC17[rip]
	call	puts@PLT
	lea	rdi, computerBoard[rip]
	call	showBoard
.L65:
	mov	BYTE PTR -14[rbp], 1
	mov	BYTE PTR -13[rbp], 1
	jmp	.L66
.L72:
	lea	rsi, computerBoard[rip]
	mov	edi, 1
	call	getShot
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L67
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC18[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR -4[rbp]
	lea	rsi, computerBoard[rip]
	mov	edi, eax
	call	noneLeft
	test	al, al
	je	.L68
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC19[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L68
.L67:
	lea	rdi, .LC20[rip]
	call	puts@PLT
.L68:
	lea	rsi, playerBoard[rip]
	mov	edi, 0
	call	getShot
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L69
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC21[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR -4[rbp]
	lea	rsi, computerBoard[rip]
	mov	edi, eax
	call	noneLeft
	test	al, al
	je	.L70
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, eax
	lea	rdi, .LC22[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L70
.L69:
	lea	rdi, .LC23[rip]
	call	puts@PLT
.L70:
	lea	rdi, playerBoard[rip]
	call	allShipsNotHit
	mov	BYTE PTR -14[rbp], al
	lea	rdi, computerBoard[rip]
	call	allShipsNotHit
	mov	BYTE PTR -13[rbp], al
.L66:
	cmp	BYTE PTR -14[rbp], 0
	je	.L71
	cmp	BYTE PTR -13[rbp], 0
	jne	.L72
.L71:
	cmp	BYTE PTR -14[rbp], 0
	je	.L73
	lea	rdi, .LC24[rip]
	call	puts@PLT
	jmp	.L74
.L73:
	lea	rdi, .LC25[rip]
	call	puts@PLT
.L74:
	lea	rdi, computerBoard[rip]
	call	showBoard
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.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	"159944.c"
	.text
	.global	dumpComputer
	.data
	.type	dumpComputer, %object
	.size	dumpComputer, 1
dumpComputer:
	.byte	1
	.comm	playerBoard,480,4
	.comm	computerBoard,480,4
	.comm	compShotBoard,480,4
	.global	__aeabi_idivmod
	.text
	.align	2
	.global	getRand
	.syntax unified
	.arm
	.fpu softvfp
	.type	getRand, %function
getRand:
	@ 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]
	str	r1, [fp, #-12]
	bl	rand
	ldr	r3, [fp, #-12]
	add	r2, r3, #1
	ldr	r3, [fp, #-8]
	sub	r3, r2, r3
	mov	r1, r3
	bl	__aeabi_idivmod
	mov	r3, r1
	mov	r2, r3
	ldr	r3, [fp, #-8]
	add	r3, r2, r3
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	getRand, .-getRand
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Give a shot (row, col):\000"
	.align	2
.LC1:
	.ascii	"%d%d\000"
	.align	2
.LC2:
	.ascii	"Invalid input\000"
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	getShot
	.syntax unified
	.arm
	.fpu softvfp
	.type	getShot, %function
getShot:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	mov	r3, r0
	str	r1, [fp, #-28]
	strb	r3, [fp, #-21]
	ldr	r3, .L14
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
.L8:
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L4
	ldr	r0, .L14+4
	bl	printf
	sub	r2, fp, #12
	sub	r3, fp, #16
	mov	r1, r3
	ldr	r0, .L14+8
	bl	__isoc99_scanf
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	ble	.L5
	ldr	r3, [fp, #-12]
	cmp	r3, #11
	bgt	.L5
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	ble	.L5
	ldr	r3, [fp, #-16]
	cmp	r3, #9
	ble	.L6
.L5:
	ldr	r0, .L14+12
	bl	puts
	b	.L8
.L4:
	mov	r1, #9
	mov	r0, #1
	bl	getRand
	mov	r3, r0
	str	r3, [fp, #-16]
	mov	r1, #11
	mov	r0, #1
	bl	getRand
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-12]
	ldr	r0, .L14+16
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r1
	ldr	r3, [r0, r3, lsl #2]
	cmp	r3, #0
	bne	.L8
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-12]
	ldr	r0, .L14+16
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r1
	mov	r2, #1
	str	r2, [r0, r3, lsl #2]
.L6:
	ldr	r3, [fp, #-16]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-28]
	add	r3, r3, r2
	ldr	r2, [fp, #-12]
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	beq	.L9
	ldr	r3, [fp, #-16]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-28]
	add	r3, r3, r2
	ldr	r2, [fp, #-12]
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	ble	.L10
	ldr	r3, [fp, #-16]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-28]
	add	r3, r3, r2
	ldr	r2, [fp, #-12]
	ldr	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-28]
	add	r3, r3, r2
	ldr	r2, [fp, #-12]
	rsb	r1, r1, #0
	str	r1, [r3, r2, lsl #2]
.L10:
	ldr	r3, [fp, #-16]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-28]
	add	r3, r3, r2
	ldr	r2, [fp, #-12]
	ldr	r3, [r3, r2, lsl #2]
	rsb	r3, r3, #0
	b	.L12
.L9:
	mov	r3, #0
.L12:
	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	.LC3
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	compShotBoard
	.size	getShot, .-getShot
	.align	2
	.global	allShipsNotHit
	.syntax unified
	.arm
	.fpu softvfp
	.type	allShipsNotHit, %function
allShipsNotHit:
	@ 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, #1
	str	r3, [fp, #-12]
	b	.L17
.L22:
	mov	r3, #1
	str	r3, [fp, #-8]
	b	.L18
.L21:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r2, [fp, #-8]
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	ble	.L19
	mov	r3, #1
	b	.L20
.L19:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L18:
	ldr	r3, [fp, #-8]
	cmp	r3, #11
	ble	.L21
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L17:
	ldr	r3, [fp, #-12]
	cmp	r3, #9
	ble	.L22
	mov	r3, #0
.L20:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	allShipsNotHit, .-allShipsNotHit
	.align	2
	.global	noneLeft
	.syntax unified
	.arm
	.fpu softvfp
	.type	noneLeft, %function
noneLeft:
	@ 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]
	str	r1, [fp, #-20]
	mov	r3, #1
	str	r3, [fp, #-12]
	b	.L24
.L29:
	mov	r3, #1
	str	r3, [fp, #-8]
	b	.L25
.L28:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-20]
	add	r3, r3, r2
	ldr	r2, [fp, #-8]
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	bne	.L26
	mov	r3, #0
	b	.L27
.L26:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L25:
	ldr	r3, [fp, #-8]
	cmp	r3, #11
	ble	.L28
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L24:
	ldr	r3, [fp, #-12]
	cmp	r3, #9
	ble	.L29
	mov	r3, #1
.L27:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	noneLeft, .-noneLeft
	.section	.rodata
	.align	2
.LC4:
	.ascii	"Rows are 1 - 9, Columns are 1 - 11\000"
	.align	2
.LC5:
	.ascii	"Orientation is 0 for across, 1 for down\000"
	.align	2
.LC6:
	.ascii	"Give starting row, starting column and orientation "
	.ascii	"(3 inputs) for ship of size=%d:\000"
	.align	2
.LC7:
	.ascii	"%d %d %d\000"
	.align	2
.LC8:
	.ascii	"Invalid Input\000"
	.align	2
.LC9:
	.ascii	"Conflicts with ship already placed\000"
	.align	2
.LC10:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	populateBoard
	.syntax unified
	.arm
	.fpu softvfp
	.type	populateBoard, %function
populateBoard:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #48
	mov	r3, r0
	str	r1, [fp, #-52]
	strb	r3, [fp, #-45]
	ldr	r3, .L56
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldrb	r3, [fp, #-45]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L31
	ldr	r0, .L56+4
	bl	puts
	ldr	r0, .L56+8
	bl	puts
.L31:
	mov	r3, #5
	str	r3, [fp, #-28]
	b	.L32
.L54:
	ldrb	r3, [fp, #-45]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L33
	ldr	r1, [fp, #-28]
	ldr	r0, .L56+12
	bl	printf
	sub	r3, fp, #32
	sub	r2, fp, #36
	sub	r1, fp, #40
	ldr	r0, .L56+16
	bl	__isoc99_scanf
	b	.L34
.L33:
	ldrb	r3, [fp, #-45]
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L34
	mov	r1, #9
	mov	r0, #1
	bl	getRand
	mov	r3, r0
	str	r3, [fp, #-40]
	mov	r1, #11
	mov	r0, #1
	bl	getRand
	mov	r3, r0
	str	r3, [fp, #-36]
	mov	r1, #1
	mov	r0, #0
	bl	getRand
	mov	r3, r0
	str	r3, [fp, #-32]
.L34:
	ldr	r3, [fp, #-40]
	cmp	r3, #0
	ble	.L35
	ldr	r3, [fp, #-40]
	cmp	r3, #9
	bgt	.L35
	ldr	r3, [fp, #-36]
	cmp	r3, #0
	ble	.L35
	ldr	r3, [fp, #-36]
	cmp	r3, #11
	bgt	.L35
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	blt	.L35
	ldr	r3, [fp, #-32]
	cmp	r3, #1
	bgt	.L35
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bne	.L36
	ldr	r2, [fp, #-36]
	ldr	r3, [fp, #-28]
	add	r3, r2, r3
	cmp	r3, #12
	bgt	.L35
.L36:
	ldr	r3, [fp, #-32]
	cmp	r3, #1
	bne	.L37
	ldr	r2, [fp, #-40]
	ldr	r3, [fp, #-28]
	add	r3, r2, r3
	cmp	r3, #10
	ble	.L37
.L35:
	ldrb	r3, [fp, #-45]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L32
	ldr	r0, .L56+20
	bl	puts
	b	.L32
.L37:
	mov	r3, #1
	strb	r3, [fp, #-41]
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bne	.L39
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L40
.L42:
	ldr	r3, [fp, #-40]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-52]
	add	r3, r3, r2
	ldr	r1, [fp, #-36]
	ldr	r2, [fp, #-24]
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	beq	.L41
	mov	r3, #0
	strb	r3, [fp, #-41]
.L41:
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L40:
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	ble	.L42
.L39:
	ldr	r3, [fp, #-32]
	cmp	r3, #1
	bne	.L43
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L44
.L46:
	ldr	r2, [fp, #-40]
	ldr	r3, [fp, #-20]
	add	r3, r2, r3
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-52]
	add	r3, r3, r2
	ldr	r2, [fp, #-36]
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	beq	.L45
	mov	r3, #0
	strb	r3, [fp, #-41]
.L45:
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L44:
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	ble	.L46
.L43:
	ldrb	r3, [fp, #-41]
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L47
	ldrb	r3, [fp, #-45]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L32
	ldr	r0, .L56+24
	bl	puts
	b	.L32
.L47:
	ldrb	r3, [fp, #-41]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L32
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bne	.L48
	ldr	r3, [fp, #-36]
	str	r3, [fp, #-16]
	b	.L49
.L50:
	ldr	r3, [fp, #-40]
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-52]
	add	r3, r3, r2
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-28]
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L49:
	ldr	r2, [fp, #-36]
	ldr	r3, [fp, #-28]
	add	r3, r2, r3
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	blt	.L50
.L48:
	ldr	r3, [fp, #-32]
	cmp	r3, #1
	bne	.L51
	ldr	r3, [fp, #-40]
	str	r3, [fp, #-12]
	b	.L52
.L53:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-52]
	add	r3, r3, r2
	ldr	r2, [fp, #-36]
	ldr	r1, [fp, #-28]
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L52:
	ldr	r2, [fp, #-40]
	ldr	r3, [fp, #-28]
	add	r3, r2, r3
	ldr	r2, [fp, #-12]
	cmp	r2, r3
	blt	.L53
.L51:
	ldr	r3, [fp, #-28]
	sub	r3, r3, #1
	str	r3, [fp, #-28]
.L32:
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bgt	.L54
	nop
	ldr	r3, .L56
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L55
	bl	__stack_chk_fail
.L55:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L57:
	.align	2
.L56:
	.word	.LC10
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.size	populateBoard, .-populateBoard
	.section	.rodata
	.align	2
.LC11:
	.ascii	"   Cols\000"
	.align	2
.LC12:
	.ascii	"    1  2  3  4  5  6  7  8  9 10 11\000"
	.align	2
.LC13:
	.ascii	"     ________________________________\000"
	.align	2
.LC14:
	.ascii	"R%d|\000"
	.align	2
.LC15:
	.ascii	"%d \000"
	.align	2
.LC16:
	.ascii	"|\000"
	.align	2
.LC17:
	.ascii	"  __________________________________\000"
	.text
	.align	2
	.global	showBoard
	.syntax unified
	.arm
	.fpu softvfp
	.type	showBoard, %function
showBoard:
	@ 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	r0, .L64
	bl	puts
	ldr	r0, .L64+4
	bl	puts
	ldr	r0, .L64+8
	bl	puts
	mov	r3, #1
	str	r3, [fp, #-12]
	b	.L59
.L63:
	ldr	r1, [fp, #-12]
	ldr	r0, .L64+12
	bl	printf
	mov	r3, #1
	str	r3, [fp, #-8]
	b	.L60
.L62:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r2, [fp, #-8]
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	blt	.L61
	mov	r0, #32
	bl	putchar
.L61:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #4
	mov	r2, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, r2
	ldr	r2, [fp, #-8]
	ldr	r3, [r3, r2, lsl #2]
	mov	r1, r3
	ldr	r0, .L64+16
	bl	printf
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L60:
	ldr	r3, [fp, #-8]
	cmp	r3, #11
	ble	.L62
	ldr	r0, .L64+20
	bl	puts
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L59:
	ldr	r3, [fp, #-12]
	cmp	r3, #9
	ble	.L63
	ldr	r0, .L64+24
	bl	puts
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L65:
	.align	2
.L64:
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.word	.LC16
	.word	.LC17
	.size	showBoard, .-showBoard
	.section	.rodata
	.align	2
.LC18:
	.ascii	"Your board is\000"
	.align	2
.LC19:
	.ascii	"\012\012Computer board is\000"
	.align	2
.LC20:
	.ascii	"HIT on size %d\012\000"
	.align	2
.LC21:
	.ascii	"Sunk computer's %d\012\000"
	.align	2
.LC22:
	.ascii	"MISS!!\000"
	.align	2
.LC23:
	.ascii	"Computer hits! Size=%d\012\000"
	.align	2
.LC24:
	.ascii	"Sunk your %d\012\000"
	.align	2
.LC25:
	.ascii	"Computer miss!\000"
	.align	2
.LC26:
	.ascii	"You win!\000"
	.align	2
.LC27:
	.ascii	"You lose.\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	mov	r0, #0
	bl	time
	mov	r3, r0
	mov	r0, r3
	bl	srand
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L67
.L70:
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L68
.L69:
	ldr	r1, .L82
	ldr	r2, [fp, #-16]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	ldr	r2, [fp, #-12]
	add	r3, r3, r2
	mov	r2, #0
	str	r2, [r1, r3, lsl #2]
	ldr	r1, .L82+4
	ldr	r2, [fp, #-16]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	ldr	r2, [fp, #-12]
	add	r3, r3, r2
	mov	r2, #0
	str	r2, [r1, r3, lsl #2]
	ldr	r1, .L82+8
	ldr	r2, [fp, #-16]
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	ldr	r2, [fp, #-12]
	add	r3, r3, r2
	mov	r2, #0
	str	r2, [r1, r3, lsl #2]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L68:
	ldr	r3, [fp, #-12]
	cmp	r3, #10
	ble	.L69
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L67:
	ldr	r3, [fp, #-16]
	cmp	r3, #8
	ble	.L70
	ldr	r1, .L82
	mov	r0, #1
	bl	populateBoard
	ldr	r1, .L82+4
	mov	r0, #0
	bl	populateBoard
	ldr	r0, .L82+12
	bl	puts
	ldr	r0, .L82
	bl	showBoard
	ldr	r3, .L82+16
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L71
	ldr	r0, .L82+20
	bl	puts
	ldr	r0, .L82+4
	bl	showBoard
.L71:
	mov	r3, #1
	strb	r3, [fp, #-18]
	mov	r3, #1
	strb	r3, [fp, #-17]
	b	.L72
.L78:
	ldr	r1, .L82+4
	mov	r0, #1
	bl	getShot
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L73
	ldr	r1, [fp, #-8]
	ldr	r0, .L82+24
	bl	printf
	ldr	r1, .L82+4
	ldr	r0, [fp, #-8]
	bl	noneLeft
	mov	r3, r0
	cmp	r3, #0
	beq	.L74
	ldr	r1, [fp, #-8]
	ldr	r0, .L82+28
	bl	printf
	b	.L74
.L73:
	ldr	r0, .L82+32
	bl	puts
.L74:
	ldr	r1, .L82
	mov	r0, #0
	bl	getShot
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L75
	ldr	r1, [fp, #-8]
	ldr	r0, .L82+36
	bl	printf
	ldr	r1, .L82+4
	ldr	r0, [fp, #-8]
	bl	noneLeft
	mov	r3, r0
	cmp	r3, #0
	beq	.L76
	ldr	r1, [fp, #-8]
	ldr	r0, .L82+40
	bl	printf
	b	.L76
.L75:
	ldr	r0, .L82+44
	bl	puts
.L76:
	ldr	r0, .L82
	bl	allShipsNotHit
	mov	r3, r0
	strb	r3, [fp, #-18]
	ldr	r0, .L82+4
	bl	allShipsNotHit
	mov	r3, r0
	strb	r3, [fp, #-17]
.L72:
	ldrb	r3, [fp, #-18]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L77
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L78
.L77:
	ldrb	r3, [fp, #-18]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L79
	ldr	r0, .L82+48
	bl	puts
	b	.L80
.L79:
	ldr	r0, .L82+52
	bl	puts
.L80:
	ldr	r0, .L82+4
	bl	showBoard
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L83:
	.align	2
.L82:
	.word	playerBoard
	.word	computerBoard
	.word	compShotBoard
	.word	.LC18
	.word	dumpComputer
	.word	.LC19
	.word	.LC20
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.word	.LC24
	.word	.LC25
	.word	.LC26
	.word	.LC27
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
