Problem: Some of you know an old story of Voronoi Island. There were N liege lords and they are always involved in territorial disputes. The residents of the island were despaired of the disputes.

One day, a clever lord proposed to stop the disputes and divide the island fairly. His idea was to divide the island such that any piece of area belongs to the load of the nearest castle. The method is called Voronoi Division today.

Actually, there are many aspects of whether the method is fair. According to one historian, the clever lord suggested the method because he could gain broader area than other lords.

Your task is to write a program to calculate the size of the area each lord can gain. You may assume that Voronoi Island has a convex shape.



Input

The input consists of multiple datasets. Each dataset has the following format:

N M
Ix1 Iy1
Ix2 Iy2
...
IxN IyN
Cx1 Cy1
Cx2 Cy2
...
CxM CyM


N is the number of the vertices of Voronoi Island; M is the number of the liege lords; (Ixi, Iyi) denotes the coordinate of the i-th vertex; (Cxi, Cyi ) denotes the coordinate of the castle of the i-the lord.

The input meets the following constraints: 3 ≤ N ≤ 10, 2 ≤ M ≤ 10, -100 ≤ Ixi, Iyi, Cxi, Cyi ≤ 100. The vertices are given counterclockwise. All the coordinates are integers.

The last dataset is followed by a line containing two zeros. This line is not a part of any dataset and should not be processed.

Output

For each dataset, print the area gained by each liege lord with an absolute error of at most 10-4 . You may output any number of digits after the decimal point. The order of the output areas must match that of the lords in the input.

Example

Input

3 3
0 0
8 0
0 8
2 2
4 2
2 4
0 0


Output

9.0
11.5
11.5

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;

#define repl(i,a,b) for(int i=(int)(a);i<(int)(b);i++)
#define rep(i,n) repl(i,0,n)
#define all(x) (x).begin(),(x).end()
#define dbg(x) cout<<#x"="<<x<<endl

typedef double D;
typedef complex<D> P;
#define X real()
#define Y imag()
const D eps=1e-8;
const D inf=1e12;
struct L : public vector<P> { // line and segment
  L(const P& a,const P &b){
    push_back(a);
    push_back(b);
  }
};
D cross(P a,P b){ return (conj(a)*b).Y; }
D dot(P a,P b){ return (conj(a)*b).X; }
int ccw(P a,P b,P c) {
  b=b-a;c=c-a;
  if(cross(b,c)>0) return +1;       // counter clockwise
  if(cross(b,c)<0) return -1;       // clockwise
  if(dot(b,c)<0)   return +2;       // c--a--b on line
  if(norm(b)<norm(c)) return -2;       // a--b--c on line
  return 0;
}
P crosspoint(L l,L m) {
  D A=cross(l[1]-l[0],m[1]-m[0]);
  D B=cross(l[1]-l[0],l[1]-m[0]);
  if (abs(A)<eps&&abs(B)<eps) return m[0]; // same line
  if (abs(A)<eps) assert(false); // !!!PRECONDITION NOT SATISFIED!!!
  return m[0]+B/A*(m[1]-m[0]);
}

vector<P> convex_cut(vector<P>& poly,L l) {
  vector<P> Q;
  int sz=poly.size();
  for (int i = 0; i < sz; i++) {
    P A = poly[i], B = poly[(i+1)%sz];
    if(ccw(l[0], l[1], A) != -1)Q.push_back(A);
    if(ccw(l[0], l[1], A)*ccw(l[0], l[1], B) < 0){
      Q.push_back(crosspoint(L(A, B), l));
    }
  }
  return Q;
}

L bisector_line(L l){
  P hp=0.5*(l[0]+l[1]);
  P v=l[1]-l[0];
  return L(hp,hp+P(-v.Y,v.X));
}

D calc_area(vector<P>& poly) {
  D res = 0;
  int sz=poly.size();
  for (int i = 0; i < sz; i++){
    res += cross(poly[i], poly[(i+1)%sz]);
  }
  return res/2.0;
}

int main(){
  while(1){
    int n,m;
    vector<P> ps,cs;
    cin>>n>>m;
    if(n==0||m==0)break;
    rep(i,n){
      D px,py;
      cin>>px>>py;
      ps.push_back(P(px,py));
    }
    rep(i,m){
      D cx,cy;
      cin>>cx>>cy;
      cs.push_back(P(cx,cy));
    }
    rep(i,m){
      vector<P> tmp=ps;
      rep(j,m){
        if(j==i)continue;
        L l=bisector_line(L(cs[i],cs[j]));
        tmp=convex_cut(tmp,l);
      }
      D res=calc_area(tmp);
      printf("%.10f\n", res);
    }
  }
  return 0;
}