#include <bits/stdc++.h>
using namespace std;
int n;
int a[200001];
map<int, int> cnt;
multiset<long long> out;
multiset<long long> in;
long long solve() {
  return (long long)((*out.rbegin()) - (*out.begin())) *
         (long long)((*in.rbegin()) - (*in.begin()));
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cin >> n;
  n *= 2;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
    cnt[a[i]]++;
    if (cnt[a[i]] == n / 2) {
      cout << 0 << '\n';
      return 0;
    }
  }
  sort(a + 1, a + 1 + n);
  for (int i = 1; i <= n / 2; i++) in.insert(a[i]);
  for (int i = n / 2; i <= n; i++) out.insert(a[i]);
  long long ret = 1e18;
  ret = solve();
  for (int i = 1; i <= n / 2; i++) {
    int nxt = i + n / 2;
    in.insert(a[nxt]);
    in.erase(in.begin());
    out.insert(a[i]);
    auto it = out.find(a[nxt]);
    out.erase(it);
    ret = min(ret, solve());
  }
  cout << ret << endl;
  return 0;
}
