#include <bits/stdc++.h>
double A[700001], ans, tmp, tt;
int l, r, n, k, i, j, jj, N;
int main() {
  scanf("%d%d", &n, &k);
  N = 700000 / k;
  for (i = 1; i <= n; i++) {
    ans = 0;
    scanf("%d", &l);
    for (j = 1; j <= k; j++) {
      scanf("%d", &r);
      tmp = (double)(r - l) / N;
      for (jj = 0; jj <= N; jj++) {
        tt = (double)l + tmp * jj;
        if (tt > A[(j - 1) * N + jj]) {
          ans += (tt - A[(j - 1) * N + jj]);
          A[(j - 1) * N + jj] = tt;
        }
      }
      l = r;
    }
    printf("%lf\n", ans / N);
  }
  return 0;
}
