#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-8;
struct point {
  point() {}
  point(double nx, double ny) { x = nx, y = ny; }
  double x, y;
  bool operator<(const point &a) const {
    if (((a.x - x < 0) ? (-(a.x - x)) : (a.x - x)) < eps)
      return y < a.y;
    else
      return x < a.x;
  }
};
struct polyline {
  polyline() {}
  vector<point> src;
};
polyline t[301];
struct line {
  double a, b, c;
  line() {}
  line(point p, point q) {
    a = p.y - q.y;
    b = q.x - p.x;
    c = -a * p.x - b * p.y;
    norm();
  }
  void norm() {
    double z = sqrt(a * a + b * b);
    if (((z < 0) ? (-(z)) : (z)) > eps) a /= z, b /= z, c /= z;
  }
  double dist(point p) const { return a * p.x + b * p.y + c; }
};
inline bool betw(double l, double r, double x) {
  return min(l, r) <= x + eps && x <= max(l, r) + eps;
}
inline bool intersect_1d(double a, double b, double c, double d) {
  if (a > b) swap(a, b);
  if (c > d) swap(c, d);
  return max(a, c) <= min(b, d) + eps;
}
bool intersect(point a, point b, point c, point d, point &left, point &right) {
  if (!intersect_1d(a.x, b.x, c.x, d.x) || !intersect_1d(a.y, b.y, c.y, d.y))
    return false;
  line m(a, b);
  line n(c, d);
  double zn = (m.a * n.b - m.b * n.a);
  if (((zn < 0) ? (-(zn)) : (zn)) < eps) {
    if (((m.dist(c) < 0) ? (-(m.dist(c))) : (m.dist(c))) > eps ||
        ((n.dist(a) < 0) ? (-(n.dist(a))) : (n.dist(a))) > eps)
      return false;
    if (b < a) swap(a, b);
    if (d < c) swap(c, d);
    left = max(a, c);
    right = min(b, d);
    return true;
  } else {
    left.x = right.x = -(m.c * n.b - m.b * n.c) / zn;
    left.y = right.y = -(m.a * n.c - m.c * n.a) / zn;
    return betw(a.x, b.x, left.x) && betw(a.y, b.y, left.y) &&
           betw(c.x, d.x, left.x) && betw(c.y, d.y, left.y);
  }
}
point get_inter(point a, point b, double x) {
  a.x -= b.x, a.y -= b.y;
  x -= b.x;
  double ny = x * a.y / a.x + b.y;
  return point(x + b.x, ny);
}
polyline *cross(polyline &s, point &a, point &b) {
  polyline *tmp = new polyline();
  for (int i = 0; i < s.src.size() - 1; i++) {
    point tt = get_inter(a, b, s.src[i].x);
    tmp->src.push_back(max(s.src[i], tt));
    point lft, rgt;
    if (intersect(a, b, s.src[i], s.src[i + 1], lft, rgt)) {
      tmp->src.push_back(lft);
      if (((lft.x - rgt.x < 0) ? (-(lft.x - rgt.x)) : (lft.x - rgt.x)) > eps ||
          ((lft.y - rgt.y < 0) ? (-(lft.y - rgt.y)) : (lft.y - rgt.y)) > eps)
        tmp->src.push_back(rgt);
    }
  }
  return tmp;
}
polyline *unite(polyline *f, polyline &simple) {
  polyline *result = new polyline();
  int cur = 0;
  for (int i = 1; i < (int)simple.src.size(); i++) {
    polyline tmp;
    while (f->src[cur].x < simple.src[i].x + eps && cur < f->src.size())
      tmp.src.push_back(f->src[cur]), cur++;
    cur--;
    polyline *ntmp = cross(tmp, simple.src[i - 1], simple.src[i]);
    for (int j = 0; j < ntmp->src.size(); j++) {
      if (result->src.size() == 0 ||
          ((result->src[result->src.size() - 1].x - ntmp->src[j].x < 0)
               ? (-(result->src[result->src.size() - 1].x - ntmp->src[j].x))
               : (result->src[result->src.size() - 1].x - ntmp->src[j].x)) >
              eps)
        result->src.push_back(ntmp->src[j]);
    }
  }
  result->src.push_back(
      point(max(f->src[f->src.size() - 1], simple.src[simple.src.size() - 1])));
  return result;
}
double get3(point a, point b, point c) {
  return a.x * (b.y - c.y) - b.x * (a.y - c.y) + c.x * (a.y - b.y);
}
int n, k;
double getSquare(polyline *tmp) {
  double ans = 0.0;
  tmp->src.push_back(point(k, 0));
  for (int i = 0; i < (int)tmp->src.size() - 1; i++)
    ans += get3(point(0, 0), tmp->src[i], tmp->src[i + 1]);
  tmp->src.pop_back();
  return ans / 2.0;
}
polyline *current;
int main() {
  cin >> n >> k;
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < k + 1; j++) {
      double y;
      cin >> y;
      t[i].src.push_back(point((double)j, y));
    }
    if (i == 0) {
      current = new polyline(t[0]);
      printf("%.10f\n", ((getSquare(current) < 0) ? (-(getSquare(current)))
                                                  : (getSquare(current))));
    } else {
      double lol = ((getSquare(current) < 0) ? (-(getSquare(current)))
                                             : (getSquare(current)));
      current = unite(current, t[i]);
      printf("%.10f\n", ((getSquare(current) < 0) ? (-(getSquare(current)))
                                                  : (getSquare(current))) -
                            lol);
    }
  }
}
