from math import acos
pi = 3.14159265358979323846264338
N = int(input())
A = [[0, 0, 0, _] for _ in range(N)]
flg = [False for _ in range(N)]
for i in range(N):
    A[i][1], A[i][2] = map(int, input().split())
    A[i][0] = A[i][1] * A[i][1] + A[i][2] * A[i][2]
X = [[A[i][1], A[i][2]] for i in range(N)]
A.sort(reverse=True)
stx, sty = A[0][1], A[0][2]
px, py = stx, sty
flg[A[0][3]] = True
prev_point = A[0][3]
convex_hull = [A[0][3]]
while True:
    min_prod2 = [[1, 1], [N+1, N+1], 1]
    for i in range(N):
        for j in range(N):
            if i != prev_point and j != prev_point:
                ffflg = True
                dx1 = X[i][0] - px
                dx2 = X[j][0] - px
                dy1 = X[i][1] - py
                dy2 = X[j][1] - py
                inner_prod = dx1 * dx2 + dy1 * dy2
                norm1 = dx1 * dx1 + dy1 * dy1
                norm2 = dx2 * dx2 + dy2 * dy2
                sign = (inner_prod > 0) - (inner_prod < 0)
                if sign < min_prod2[2]:
                    min_prod2[0] = [inner_prod*inner_prod, norm1*norm2]
                    min_prod2[1] = [i, j]
                    min_prod2[2] = sign
                elif sign == min_prod2[2]:
                    if sign == 1:
                        if min_prod2[0][0] * norm1 * norm2 > inner_prod * inner_prod * min_prod2[0][1]:
                            min_prod2[0] = [inner_prod*inner_prod, norm1*norm2]
                            min_prod2[1] = [i, j]
                        elif min_prod2[0][0] * norm1 * norm2 == inner_prod * inner_prod * min_prod2[0][1]:
                            if min_prod2[0][1] > norm1 * norm2 or min_prod2[1] == [N+1, N+1]:
                                min_prod2[0] = [inner_prod*inner_prod, norm1*norm2]
                                min_prod2[1] = [i, j]
                    elif sign == 0:
                        if min_prod2[0][1] > norm1 * norm2 or min_prod2[1] == [N+1, N+1]:
                            min_prod2[0] = [inner_prod*inner_prod, norm1*norm2]
                            min_prod2[1] = [i, j]
                    else:
                        if min_prod2[0][0] * norm1 * norm2 < inner_prod * inner_prod * min_prod2[0][1]:
                            min_prod2[0] = [inner_prod*inner_prod, norm1*norm2]
                            min_prod2[1] = [i, j]
                        elif min_prod2[0][0] * norm1 * norm2 == inner_prod * inner_prod * min_prod2[0][1]:
                            if min_prod2[0][1] > norm1 * norm2 or min_prod2[1] == [N+1, N+1]:
                                min_prod2[0] = [inner_prod*inner_prod, norm1*norm2]
                                min_prod2[1] = [i, j]
    if flg[min_prod2[1][0]] and flg[min_prod2[1][1]]:
        break
    else:
        if flg[min_prod2[1][0]] and not flg[min_prod2[1][1]]:
            prev_point = min_prod2[1][1]
        elif not flg[min_prod2[1][0]] and flg[min_prod2[1][1]]:
            prev_point = min_prod2[1][0]
        elif not flg[min_prod2[1][0]] and not flg[min_prod2[1][1]]:
            prev_point = min_prod2[1][0]
        convex_hull.append(prev_point)
        flg[prev_point] = True
        px, py = X[prev_point][0], X[prev_point][1]
M = len(convex_hull)
prob = [0 for _ in range(N)]
for i in range(M):
    center = convex_hull[i]
    ii, jj = convex_hull[(i-1)%M], convex_hull[(i+1)%M]
    dx1 = X[ii][0] - X[center][0]
    dx2 = X[jj][0] - X[center][0]
    dy1 = X[ii][1] - X[center][1]
    dy2 = X[jj][1] - X[center][1]
    ip = dx1 * dx2 + dy1 * dy2
    n1 = dx1 * dx1 + dy1 * dy1
    n2 = dx2 * dx2 + dy2 * dy2
    n1 = n1**0.5
    n2 = n2**0.5
    prob[center] = 0.5 - (acos((ip/n1)/n2))/(2*pi)
for i in range(N):
    print(prob[i])

Measured memory_bytes: 9572