#include <bits/stdc++.h>
using namespace std;
int n, k;
pair<int, int> c[123456];
int dd[123456], gg[123456], ll[123456], pp[123456];
bool cmpd(int i, int j) {
  if (c[i].second == c[j].second) return c[i].first < c[j].first;
  return c[i].second < c[j].second;
}
bool cmpg(int i, int j) {
  if (c[i].second == c[j].second) return c[i].first < c[j].first;
  return c[i].second > c[j].second;
}
bool cmpl(int i, int j) {
  if (c[i].first == c[j].first) return c[i].second < c[j].second;
  return c[i].first < c[j].first;
}
bool cmpp(int i, int j) {
  if (c[i].first == c[j].first) return c[i].second < c[j].second;
  return c[i].first > c[j].first;
}
long long pol(int i, int j, int l, int m) {
  long long pole;
  int ab[12];
  int z = 0;
  for (int x = 0; x <= (i - 1); ++x) {
    ab[z] = ll[x];
    z++;
  }
  for (int x = 0; x <= (j - 1); ++x) {
    ab[z] = pp[x];
    z++;
  }
  for (int x = 0; x <= (l - 1); ++x) {
    ab[z] = gg[x];
    ++z;
  }
  for (int x = 0; x <= (m - 1); ++x) {
    ab[z] = dd[x];
    ++z;
  }
  for (int x = 0; x < (n); ++x) {
    bool fl = 0;
    for (int x = 0; x <= (z - 1); ++x)
      if (ab[x] == ll[i]) {
        fl = 1;
        ++i;
        break;
      }
    if (!fl) break;
  }
  for (int x = 0; x < (n); ++x) {
    bool fl = 0;
    for (int x = 0; x <= (z - 1); ++x)
      if (ab[x] == pp[j]) {
        fl = 1;
        ++j;
        break;
      }
    if (!fl) break;
  }
  for (int x = 0; x < (n); ++x) {
    bool fl = 0;
    for (int x = 0; x <= (z - 1); ++x)
      if (ab[x] == gg[l]) {
        fl = 1;
        ++l;
        break;
      }
    if (!fl) break;
  }
  for (int x = 0; x < (n); ++x) {
    bool fl = 0;
    for (int x = 0; x <= (z - 1); ++x)
      if (ab[x] == dd[m]) {
        fl = 1;
        ++m;
        break;
      }
    if (!fl) break;
  }
  long long x = c[pp[j]].first - c[ll[i]].first;
  long long y = c[gg[l]].second - c[dd[m]].second;
  x = (x + 1) / 2;
  y = (y + 1) / 2;
  if (x <= 0) x = 1;
  if (y <= 0) y = 1;
  return x * y;
}
int main() {
  int x1, y1, x2, y2;
  cin >> n >> k;
  for (int i = 0; i <= (n - 1); ++i) {
    cin >> x1 >> y1 >> x2 >> y2;
    c[i] = make_pair(x1 + x2, y1 + y2);
    dd[i] = gg[i] = ll[i] = pp[i] = i;
  }
  sort(dd, dd + n, cmpd);
  sort(gg, gg + n, cmpg);
  sort(ll, ll + n, cmpl);
  sort(pp, pp + n, cmpp);
  long long pole = INT_MAX - 4;
  pole *= pole;
  for (int i = 0; i <= (k); ++i)
    for (int j = 0; j <= (k); ++j)
      for (int l = 0; l <= (k); ++l)
        for (int m = 0; m <= (k); ++m) {
          if (i + j + l + m > k) continue;
          pole = min(pole, pol(i, j, l, m));
        }
  cout << pole << endl;
}
