#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ scanf(char *, ...);
int /*<<< orphan*/ stanibatka(float, float, float *, float *, int);
int main() {
  int bidoni, i;
  float xpos, ypos, xcoord[1000], ycoord[1000];
  scanf("%d", &bidoni);
  scanf("%f", &xpos);
  scanf("%f", &ypos);
  for (i = 0; i < bidoni; i++) {
    scanf("%f", &xcoord[i]);
    scanf("%f", &ycoord[i]);
  }
  stanibatka(xpos, ypos, xcoord, ycoord, bidoni);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1f60,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xec7(%rip),%rdi
lea    -0x8(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
lea    0xeb8(%rip),%rdi
lea    -0x10(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
lea    0xea6(%rip),%rdi
lea    -0x14(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11c9 <main+0xa9>
movslq -0xc(%rbp),%rax
lea    -0xfc0(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe6f(%rip),%rdi
mov    $0x0,%al
call   1040 <scanf@plt>
movslq -0xc(%rbp),%rax
lea    -0x1f60(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe4f(%rip),%rdi
mov    $0x0,%al
call   1040 <scanf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    116f <main+0x4f>
movss  -0x10(%rbp),%xmm0
movss  -0x14(%rbp),%xmm1
lea    -0xfc0(%rbp),%rdi
lea    -0x1f60(%rbp),%rsi
mov    -0x8(%rbp),%edx
call   1030 <stanibatka@plt>
xor    %eax,%eax
add    $0x1f60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x1f58,%rsp
lea    0xecb(%rip),%rdi
lea    0x4(%rsp),%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
lea    0xebb(%rip),%rbx
lea    0xc(%rsp),%rsi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <scanf@plt>
lea    0x8(%rsp),%rsi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <scanf@plt>
mov    0x4(%rsp),%edx
test   %edx,%edx
jle    11c0 <main+0xa0>
lea    0x10(%rsp),%r14
lea    0xfb0(%rsp),%r12
lea    0xe81(%rip),%r15
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %r15,%rdi
mov    %r12,%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
mov    %r15,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
add    $0x1,%rbx
movslq 0x4(%rsp),%rdx
add    $0x4,%r14
add    $0x4,%r12
cmp    %rdx,%rbx
jl     1190 <main+0x70>
movss  0xc(%rsp),%xmm0
movss  0x8(%rsp),%xmm1
lea    0xfb0(%rsp),%rdi
lea    0x10(%rsp),%rsi
call   1030 <stanibatka@plt>
xor    %eax,%eax
add    $0x1f58,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [3 x i8] c"%f\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca float
%5 = alloca float
%6 = alloca [1000 x float]
%7 = alloca [1000 x float]
store i32 0, i32* %1
%8 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%9 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %4)
%10 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %5)
store i32 0, i32* %3
br label %11
11: ; preds = %24, %0
%12 = load i32, i32* %3
%13 = load i32, i32* %2
%14 = icmp slt i32 %12, %13
br i1 %14, label %15, label %27
15: ; preds = %11
%16 = load i32, i32* %3
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds [1000 x float], [1000 x float]* %6, i64 0, i64 %17
%19 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %18)
%20 = load i32, i32* %3
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds [1000 x float], [1000 x float]* %7, i64 0, i64 %21
%23 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %22)
br label %24
24: ; preds = %15
%25 = load i32, i32* %3
%26 = add nsw i32 %25, 1
store i32 %26, i32* %3
br label %11
27: ; preds = %11
%28 = load float, float* %4
%29 = load float, float* %5
%30 = getelementptr inbounds [1000 x float], [1000 x float]* %6, i64 0, i64 0
%31 = getelementptr inbounds [1000 x float], [1000 x float]* %7, i64 0, i64 0
%32 = load i32, i32* %2
%33 = call i32 @stanibatka(float %28, float %29, float* %30, float* %31, i32 %32)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [3 x i8] c"%f\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca [1000 x float]
%5 = alloca [1000 x float]
%6 = bitcast i32* %1 to i8*
%7 = bitcast float* %2 to i8*
%8 = bitcast float* %3 to i8*
%9 = bitcast [1000 x float]* %4 to i8*
%10 = bitcast [1000 x float]* %5 to i8*
%11 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%12 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %2)
%13 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %3)
%14 = load i32, i32* %1
%15 = icmp sgt i32 %14, 0
br i1 %15, label %16, label %26
16: ; preds = %0, %16
%17 = phi i64 [ %22, %16 ], [ 0, %0 ]
%18 = getelementptr inbounds [1000 x float], [1000 x float]* %4, i64 0, i64 %17
%19 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %18)
%20 = getelementptr inbounds [1000 x float], [1000 x float]* %5, i64 0, i64 %17
%21 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %20)
%22 = add nuw nsw i64 %17, 1
%23 = load i32, i32* %1
%24 = sext i32 %23 to i64
%25 = icmp slt i64 %22, %24
br i1 %25, label %16, label %26
26: ; preds = %16, %0
%27 = phi i32 [ %14, %0 ], [ %23, %16 ]
%28 = load float, float* %2
%29 = load float, float* %3
%30 = getelementptr inbounds [1000 x float], [1000 x float]* %4, i64 0, i64 0
%31 = getelementptr inbounds [1000 x float], [1000 x float]* %5, i64 0, i64 0
%32 = call i32 @stanibatka(float %28, float %29, float* %30, float* %31, i32 %27)
ret i32 0
}