#include <bits/stdc++.h>
using namespace std;
const int N = 100;
long long n, m, xa, ya, xb, yb;
int main() {
  cin >> n;
  long long a[n * 2 + 123], b[n + 123];
  for (int i = 1; i <= n * 2; i++) cin >> a[i];
  sort(a + 1, a + n * 2 + 1);
  xa = 1;
  for (int i = 2; i <= n * 2; i++) {
    if (a[i] == a[i - 1])
      xa++;
    else
      xa = 1;
    if (xa >= n) return cout << 0, 0;
  }
  ya = 1e18;
  xb = 1;
  for (int i = 2; i <= n * 2 - n + 1; i++) {
    ya = min(ya, (a[i + n - 1] - a[i]) * (a[2 * n] - a[1]));
  }
  ya = min(ya, (a[n] - a[1]) * (a[n * 2] - a[n + 1]));
  cout << ya;
  return 0;
}
