#include <bits/stdc++.h>
using namespace std;
int sx[100010], sy[100010], fx[100010], fy[100010];
int vh[100010], vv[100010];
int sv(int a, int b) { return sy[a] < sy[b]; }
int sh(int a, int b) { return sx[a] < sx[b]; }
int n;
long long ans;
int done[100010];
int u, d, l, r;
int uy, dy, lx, rx;
vector<int> wu, wd, wl, wr;
void clear(vector<int> &w) {
  for (int i = 0; i < w.size(); i++) {
    done[w[i]] = 0;
  }
  w.clear();
}
void gor(int re) {
  for (r = n - 1; re && r > l; r--) {
    if (done[vh[r]]) {
      continue;
    }
    --re;
    done[vh[r]] = 1;
    wr.push_back(vh[r]);
  }
  for (int i = 0; i < n; i++) {
    if (!done[vv[i]]) {
      uy = sy[vv[i]];
      break;
    }
  }
  for (int i = 0; i < n; i++) {
    if (!done[vh[i]]) {
      lx = sx[vh[i]];
      break;
    }
  }
  for (int i = n - 1; i >= 0; i--) {
    if (!done[vv[i]]) {
      dy = sy[vv[i]];
      break;
    }
  }
  for (int i = n - 1; i >= 0; i--) {
    if (!done[vh[i]]) {
      rx = sx[vh[i]];
      break;
    }
  }
  long long ay = (dy - uy + 1) / 2, ax = (rx - lx + 1) / 2;
  ay = max(ay, 1ll);
  ax = max(ax, 1ll);
  ans = min(ans, ay * ax);
  clear(wr);
}
void gol(int re) {
  for (l = 0; re; l++) {
    if (done[vh[l]]) {
      continue;
    }
    gor(re);
    --re;
    done[vh[l]] = 1;
    wl.push_back(vh[l]);
  }
  gor(re);
  clear(wl);
}
void god(int re) {
  for (d = n - 1; re && d > u; d--) {
    if (done[vv[d]]) {
      continue;
    }
    gol(re);
    --re;
    done[vv[d]] = 1;
    wd.push_back(vv[d]);
  }
  gol(re);
  clear(wd);
}
void gou(int re) {
  for (u = 0; re; u++) {
    god(re);
    --re;
    done[vv[u]] = 1;
    wu.push_back(vv[u]);
  }
  god(re);
  clear(wu);
}
int main() {
  int k;
  scanf("%d%d", &n, &k);
  for (int i = 0; i < n; i++) {
    scanf("%d%d%d%d", &sx[i], &sy[i], &fx[i], &fy[i]);
    sx[i] = sx[i] + fx[i];
    sy[i] = sy[i] + fy[i];
    vv[i] = vh[i] = i;
  }
  sort(vv, vv + n, sv);
  sort(vh, vh + n, sh);
  ans = 1ll << 61;
  gou(k);
  printf("%I64d\n", ans);
  return 0;
}
