#include <bits/stdc++.h>
using namespace std;
const int N = 400, mod = int(1e9) + 7;
int n, k;
long double ans, cur;
int x[N];
pair<int, int> line[N][N];
int sz[N];
pair<int, int> rb[N];
int an;
long long A, C, A1, C1;
bool ok = 0;
long double getx(pair<int, int> x, pair<int, int> y, int i) {
  A = x.first - x.second;
  C = x.second * (i - 1) - x.first * i;
  A1 = y.first - y.second;
  C1 = y.second * (i - 1) - y.first * i;
  return (C - C1 + 0.0) / (A1 - A);
}
void add_line(int i, pair<int, int> p) {
  int k = sz[i];
  while (k > 1) {
    long double x1 = getx(line[i][k], line[i][k - 1], i);
    long double x2 = getx(line[i][k], p, i);
    if (x2 > x1) break;
    k--;
  }
  line[i][++k] = p;
  sz[i] = k;
}
void add(int i) {
  an = 0;
  if (sz[i] == 0) {
    rb[++an] = make_pair(x[i - 1], x[i]);
  } else {
    bool first = 0;
    for (int j = 1; j <= sz[i]; j++) {
      if (!first && x[i - 1] > line[i][j].first ||
          (x[i - 1] == line[i][j].first && x[i] > line[i][j].second)) {
        rb[++an] = make_pair(x[i - 1], x[i]);
        first = 1;
      }
      rb[++an] = line[i][j];
    }
    if (!first) rb[++an] = make_pair(x[i - 1], x[i]);
  }
  int k = 1;
  line[i][1] = rb[1];
  int mx = rb[1].second;
  sz[i] = 1;
  for (int j = 2; j <= an; j++) {
    if (mx < rb[j].second) {
      add_line(i, rb[j]);
      mx = rb[j].second;
    }
  }
}
long double get(int i) {
  int k = sz[i];
  long double res = 0;
  long double x, y, px, py;
  px = i - 1;
  py = line[i][1].first;
  for (int j = 2; j <= k; j++) {
    x = getx(line[i][j], line[i][j - 1], i);
    y = (C1 * A - C * A1 + 0.0) / (A1 - A);
    res += (x - px) * (y + py) / 2.0;
    py = y;
    px = x;
  }
  x = i;
  y = line[i][k].second;
  res += (x - px) * (y + py) / 2.0;
  return res;
}
int main() {
  scanf("%d%d", &n, &k);
  for (int i = 0; i <= k; i++) {
    scanf("%d", &x[i]);
    if (i > 0) {
      ans += (x[i] + x[i - 1]) / 2.0;
      add(i);
    }
  }
  printf("%.12lf\n", (double)ans);
  for (int it = 2; it <= n; it++) {
    cur = ans;
    ans = 0;
    ok = 0;
    for (int i = 0; i <= k; i++) {
      scanf("%d", &x[i]);
      if (i > 0) add(i);
    }
    for (int i = 1; i <= k; i++) {
      ans += get(i);
    }
    printf("%.12lf\n", double(ans - cur));
  }
  return 0;
}
