	.file	"941341.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"lab1.sql"
.LC1:
	.string	"Can't open database: %s\n"
	.align 8
.LC2:
	.ascii	"WITH RECURSIVE reached(destination_airport_ID)"
	.string	" AS(select destination_airport_ID from routes where source_airport = ? UNION select r.destination_airport_ID from reached re, routes r where re.destination_airport_ID = r.source_airport_ID) select source_airport_ID from routes except select * from reached;"
.LC3:
	.string	"Preparation failed: %s\n"
.LC4:
	.string	"enter id: "
.LC5:
	.string	"%s"
	.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, 64
	mov	DWORD PTR -52[rbp], edi
	mov	QWORD PTR -64[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	call	sqlite3_open@PLT
	mov	DWORD PTR -44[rbp], eax
	cmp	DWORD PTR -44[rbp], 0
	je	.L2
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	sqlite3_errmsg@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	sqlite3_close@PLT
	mov	eax, 1
	jmp	.L5
.L2:
	lea	rax, .LC2[rip]
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -40[rbp]
	lea	rdx, -32[rbp]
	mov	rsi, QWORD PTR -24[rbp]
	mov	r8d, 0
	mov	rcx, rdx
	mov	edx, -1
	mov	rdi, rax
	call	sqlite3_prepare_v2@PLT
	mov	DWORD PTR -44[rbp], eax
	cmp	DWORD PTR -44[rbp], 0
	je	.L4
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	sqlite3_errmsg@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	sqlite3_close@PLT
	mov	eax, 1
	jmp	.L5
.L4:
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -12[rbp]
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	rax, QWORD PTR -32[rbp]
	lea	rdx, -12[rbp]
	mov	r8d, 0
	mov	ecx, -1
	mov	esi, 1
	mov	rdi, rax
	call	sqlite3_bind_text@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	print_result
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	sqlite3_reset@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	sqlite3_clear_bindings@PLT
	mov	rax, QWORD PTR -32[rbp]
	mov	rdi, rax
	call	sqlite3_finalize@PLT
	mov	rax, QWORD PTR -40[rbp]
	mov	rdi, rax
	call	sqlite3_close@PLT
	mov	eax, 0
.L5:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L6
	call	__stack_chk_fail@PLT
.L6:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
.LC6:
	.string	"%s|"
	.text
	.globl	print_result
	.type	print_result, @function
print_result:
.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
	jmp	.L8
.L11:
	mov	DWORD PTR -8[rbp], 0
	jmp	.L9
.L10:
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	sqlite3_column_text@PLT
	mov	rsi, rax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -8[rbp], 1
.L9:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	sqlite3_column_count@PLT
	sub	eax, 1
	cmp	DWORD PTR -8[rbp], eax
	jl	.L10
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	sqlite3_column_text@PLT
	mov	rsi, rax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 10
	call	putchar@PLT
.L8:
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	sqlite3_step@PLT
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 100
	je	.L11
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	print_result, .-print_result
	.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	"941341.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"lab1.sql\000"
	.align	2
.LC1:
	.ascii	"Can't open database: %s\012\000"
	.align	2
.LC2:
	.ascii	"WITH RECURSIVE reached(destination_airport_ID) AS(s"
	.ascii	"elect destination_airport_ID from routes where sour"
	.ascii	"ce_airport = ? UNION select r.destination_airport_I"
	.ascii	"D from reached re, routes r where re.destination_ai"
	.ascii	"rport_ID = r.source_airport_ID) select source_airpo"
	.ascii	"rt_ID from routes except select * from reached;\000"
	.align	2
.LC3:
	.ascii	"Preparation failed: %s\012\000"
	.align	2
.LC4:
	.ascii	"enter id: \000"
	.align	2
.LC5:
	.ascii	"%s\000"
	.align	2
.LC6:
	.word	__stack_chk_guard
	.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	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #44
	str	r0, [fp, #-40]
	str	r1, [fp, #-44]
	ldr	r3, .L7
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #36
	mov	r1, r3
	ldr	r0, .L7+4
	bl	sqlite3_open
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	beq	.L2
	ldr	r3, .L7+8
	ldr	r4, [r3]
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	sqlite3_errmsg
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L7+12
	mov	r0, r4
	bl	fprintf
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	sqlite3_close
	mov	r3, #1
	b	.L5
.L2:
	ldr	r3, .L7+16
	str	r3, [fp, #-24]
	ldr	r0, [fp, #-36]
	sub	r3, fp, #32
	mov	r2, #0
	str	r2, [sp]
	mvn	r2, #0
	ldr	r1, [fp, #-24]
	bl	sqlite3_prepare_v2
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	beq	.L4
	ldr	r3, .L7+8
	ldr	r4, [r3]
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	sqlite3_errmsg
	mov	r3, r0
	mov	r2, r3
	ldr	r1, .L7+20
	mov	r0, r4
	bl	fprintf
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	sqlite3_close
	mov	r3, #1
	b	.L5
.L4:
	ldr	r0, .L7+24
	bl	printf
	sub	r3, fp, #20
	mov	r1, r3
	ldr	r0, .L7+28
	bl	__isoc99_scanf
	ldr	r0, [fp, #-32]
	sub	r2, fp, #20
	mov	r3, #0
	str	r3, [sp]
	mvn	r3, #0
	mov	r1, #1
	bl	sqlite3_bind_text
	ldr	r3, [fp, #-32]
	mov	r0, r3
	bl	print_result
	ldr	r3, [fp, #-32]
	mov	r0, r3
	bl	sqlite3_reset
	ldr	r3, [fp, #-32]
	mov	r0, r3
	bl	sqlite3_clear_bindings
	ldr	r3, [fp, #-32]
	mov	r0, r3
	bl	sqlite3_finalize
	ldr	r3, [fp, #-36]
	mov	r0, r3
	bl	sqlite3_close
	mov	r3, #0
.L5:
	ldr	r2, .L7
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L6
	bl	__stack_chk_fail
.L6:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L8:
	.align	2
.L7:
	.word	.LC6
	.word	.LC0
	.word	stderr
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	main, .-main
	.section	.rodata
	.align	2
.LC7:
	.ascii	"%s|\000"
	.text
	.align	2
	.global	print_result
	.syntax unified
	.arm
	.fpu softvfp
	.type	print_result, %function
print_result:
	@ 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]
	b	.L10
.L13:
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L11
.L12:
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-16]
	bl	sqlite3_column_text
	mov	r3, r0
	mov	r1, r3
	ldr	r0, .L14
	bl	printf
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L11:
	ldr	r0, [fp, #-16]
	bl	sqlite3_column_count
	mov	r3, r0
	sub	r3, r3, #1
	ldr	r2, [fp, #-12]
	cmp	r2, r3
	blt	.L12
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-16]
	bl	sqlite3_column_text
	mov	r3, r0
	mov	r1, r3
	ldr	r0, .L14+4
	bl	printf
	mov	r0, #10
	bl	putchar
.L10:
	ldr	r0, [fp, #-16]
	bl	sqlite3_step
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #100
	beq	.L13
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L15:
	.align	2
.L14:
	.word	.LC7
	.word	.LC5
	.size	print_result, .-print_result
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
