#include #include double pi = acos(-1.0); int N,L[1010]; void dif(int &a1, int &a2, int l) { if (l <= a1) a1 -= l; else if (a2 <= l) a1 = l - a2; else a1 = 0; a2 += l; } double ar(int l, int r1, int r2) { if (r1 == 0 || r2 == 0) return 0; if (l >= r1 + r2) return 0; if (r1 + l <= r2) return r1 * r1 * pi; if (r2 + l <= r1) return r2 * r2 * pi; double a1 = r1 * r1 * acos((l * l + r1 * r1 - r2 * r2) / (2. * l * r1)); double a2 = r2 * r2 * acos((l * l + r2 * r2 - r1 * r1) / (2. * l * r2)); double a3 = sqrt(1. * (-l + r1 + r2) * (l - r1 + r2) * (l + r1 - r2) * (l + r1 + r2)) / 2; return a1 + a2 - a3; } int main() { scanf ("%d",&N); for (int i=0;i<=N+1;i++) scanf ("%d",&L[i]); for (int i=1;i<=N;i++){ int a1 = L[1], a2 = L[1]; for (int j=2;j<=i;j++) dif(a1, a2, L[j]); int b1 = L[N+1], b2 = L[N+1]; for (int j=N;j>i;j--) dif(b1, b2, L[j]); double ans = 0; ans += ar(L[0],a1,b1); ans -= ar(L[0],a2,b1); ans -= ar(L[0],a1,b2); ans += ar(L[0],a2,b2); printf ("%.12lf\n",ans); } return 0; }