#include <bits/stdc++.h>
#define ll long long

using namespace std;

const ll INF = 1e9;

struct TVector {
    ll x, y, id;
};

const double PI = acos(-1);
const long double EPS = 1e-8;

struct TLine {
    ll a, b, c;
    TLine(TVector A, TVector B) {
        a = A.y - B.y;
        b = B.x - A.x;
        c = A.y * B.x - B.y * A.x;
    }
    TLine(ll a1, ll b1, ll c1) {
        a = a1;
        b = b1;
        c = c1;
    }
    ll rast(TVector A) {
        ll top = abs(a * A.x + b * A.y - c);
        ll bot = sqrtl(a * a + b * b);
        if (abs(bot) < EPS) return 0;
        return top / bot;
    }
};

inline TVector operator+(TVector a, TVector b) {
    return TVector({a.x + b.x, a.y + b.y});
}

TVector operator-(TVector a, TVector b) {
    return TVector({a.x - b.x, a.y - b.y});
}

inline TVector operator*(TVector a, ll k) {
    return TVector({a.x * k, a.y * k});
}

inline ll operator%(TVector a, TVector b) {
    return a.x * b.x + a.y * b.y;
}

inline ll operator*(TVector a, TVector b) {
    return a.x * b.y - a.y * b.x;
}

inline bool operator==(TVector a, TVector b) {
    return abs(a.x - b.x) < EPS && abs(a.y - b.y) < EPS;
}

bool operator!=(TVector a, TVector b) {
    return !(a == b);
}
inline ll len(TVector a) {
    return sqrt(a % a);
}

inline TVector norm(TVector a) {
    return TVector({a.x / len(a), a.y / len(a)});
}

inline ll rast(TVector A, TVector B, TVector X) {
    TVector v1 = X - A;
    TVector v2 = B - A;
    TVector v3 = X - B;
    if (((v2 % v1 > 0) || (abs(v2 % v1) < EPS)) && ((v2 % v2 >= v2 % v1) || (abs(v2 % v2 - v2 % v1) < EPS))) {
        TLine l = TLine(A, B);
        return l.rast(X);
    }
    return min(len(v3), len(v1));
}

inline ll rast1(TVector A, TVector B, TVector X) {
    TVector v1 = X - A;
    TVector v2 = B - A;
    TVector v3 = X - B;
    if (((v2 % v1 > 0) || (abs(v2 % v1) < EPS))) {
        TLine l = TLine(A, B);
        return l.rast(X);
    }
    return min(len(v3), len(v1));
}

inline ll rast(TVector A, TVector B, TVector C, TVector D) {
    TLine l1 = TLine(A, B), l2 = TLine(C, D);
    TVector v1 = A - D, v2 = A - C, v3 = B - C, v4 = B - D;
    ll fmin = min(len(v1), min(len(v2), min(len(v3), len(v4))));
    ll smin = min(l1.rast(C), min(l1.rast(D), min(l2.rast(C), l2.rast(D))));
    return min(fmin, smin);
}

bool cmp(TVector a, TVector b) {
    if (abs(a.x - b.x) < EPS) {
        return a.y < b.y;
    }
    return a.x < b.x;
}

int main() {
    #ifdef MY
        freopen("input.txt", "r", stdin);
        //freopen("output.txt", "w", stdout);
    #else
        //freopen(TASKNAME".in", "r", stdin);
        //freopen(TASKNAME".out", "w", stdout);
        ios_base::sync_with_stdio(false);
        cin.tie(0);
        cout.tie(0);
    #endif // MY
    cout << setprecision(20);
    int n;
    cin >> n;
    vector <TVector> data(n);
    for (int i = 0; i < n; i++) {
        TVector A;
        cin >> A.x >> A.y;
        A.id = i;
        data[i] = A;
    }
    sort(data.begin(), data.end(), cmp);
    TVector A = data[0], B = data[n - 1];
    vector <TVector> data1;
    vector <TVector> top, bot;
    top.push_back(A);
    bot.push_back(A);
    data1.push_back(A);
    /*if (A == B) {
        cout << 1 << endl;
        cout << A.x << " " << A.y << endl;
        return 0;
    }*/
    for (int i = 1; i < n; i++) {
        if (data[i] == data[i - 1]) continue;
        data1.push_back(data[i]);
    }
    /*for (int i = 0; i < data1.size(); i++) {
        cout << data1[i].x << " " << data1[i].y << endl;
    }*/
    TVector AB = B - A;
    for (int i = 1; i < data1.size(); i++) {
        TVector v1 = data1[i] - A;
        TVector P = data1[i];
        if (P != B && AB * v1 == 0) {
            continue;
        }
        if (AB * v1 >= 0) {
            TVector prev = top.back();
            top.pop_back();
            while (!top.empty() && (prev - top.back()) * (P - top.back()) >= 0) {
                prev = top.back();
                top.pop_back();
            }
            top.push_back(prev);
            top.push_back(P);
        }
        if (AB * v1 <= 0) {
            TVector prev = bot.back();
            bot.pop_back();
            while (!bot.empty() && (prev - bot.back()) * (P - bot.back()) <= 0) {
                prev = bot.back();
                bot.pop_back();
            }
            bot.push_back(prev);
            bot.push_back(P);
        }
    }
    vector <TVector> hull;
    for (int i = 0; i < top.size() - 1; i++) {
        hull.push_back(top[i]);
    }
    hull.push_back(B);
    for (int j = bot.size() - 2; j > 0; j--) {
        hull.push_back(bot[j]);
    }
//    for (auto p : hull) {
//        cout << p.id << " ";
//    }
//    cout << "\n";
    vector <double> prob(n, 0);
    if (hull.size() == 2) {
        for (auto p : hull) {
            prob[p.id] = 0.5;
        }
    } else {
        for (int i = 0; i < (int) hull.size(); i++) {
            TVector A = hull[i], B = hull[(i + 1) % hull.size()], C = hull[(i + 2) % hull.size()];
            int id = B.id;
            TVector v = A - B, u = C - B;
            prob[id] = (PI - atan2(v * u, v % u)) / (2 * PI);
        }
    }
    cout.precision(20);
    for (ll i = 0; i < n; i++) {
        cout << prob[i] << "\n";
    }
}


Measured memory_bytes: 256