#include <bits/stdc++.h>
using namespace std;
template <class T>
ostream &operator<<(ostream &os, vector<T> V) {
  for (auto &v : V) os << v << " ";
  return os << "\n";
}
template <class T>
ostream &operator<<(ostream &os, set<T> V) {
  for (auto &v : V) os << v << " ";
  return os << "\n";
}
template <class T, class Y>
ostream &operator<<(ostream &os, map<T, Y> V) {
  for (auto &v : V) os << v << " ";
  return os << "\n";
}
template <class T, class Y>
ostream &operator<<(ostream &os, unordered_map<T, Y> V) {
  for (auto &v : V) os << v << " ";
  return os << "\n";
}
vector<long long> primes = {7, 17, 33, 257, 65537, 1000000007, 1000000009};
const int BASE = 1024 * 256;
int N;
int x;
vector<int> p;
int tree[2 * BASE][2];
void set_value(int x, int v) {
  v += BASE;
  tree[v][0] = tree[v][1] = x;
  v /= 2;
  while (v) {
    tree[v][0] = max(tree[2 * v][0], tree[2 * v + 1][0]);
    tree[v][1] = min(tree[2 * v][1], tree[2 * v + 1][1]);
    v /= 2;
  }
}
pair<int, int> get_values(int l, int p) {
  if (l > p) return make_pair((int)1e9, 0);
  l += BASE - 1;
  p += BASE + 1;
  int result[2] = {0, (int)1e9};
  while (l / 2 != p / 2) {
    if (l % 2 == 0) {
      result[0] = max(result[0], tree[l + 1][0]);
      result[1] = min(result[1], tree[l + 1][1]);
    }
    if (p % 2 == 1) {
      result[0] = max(result[0], tree[p - 1][0]);
      result[1] = min(result[1], tree[p - 1][1]);
    }
    l /= 2;
    p /= 2;
  }
  return make_pair(result[1], result[0]);
}
int main() {
  ios_base::sync_with_stdio(false);
  cout.tie(NULL);
  cerr.tie(NULL);
  cin.tie(NULL);
  cin >> N;
  if (N == 1) {
    cout << 0 << "\n";
    return 0;
  }
  for (auto i = 0; i < 2 * N; ++i) {
    cin >> x;
    p.emplace_back(x);
  }
  sort((p).begin(), (p).end());
  for (auto i = 0; i < 2 * N; ++i) set_value(p[i], i);
  unsigned long long answer = (unsigned long long)1e19;
  for (auto i = 0; i < N; ++i) {
    auto x = get_values(i, N - 1 + i);
    auto y1 = get_values(0, i - 1);
    auto y2 = get_values(N + i, 2 * N - 1);
    pair<int, int> y =
        make_pair(min(y1.first, y2.first), max(y1.second, y2.second));
    answer = min(answer, (unsigned long long)(abs(x.first - x.second)) *
                             (unsigned long long)(abs(y.first - y.second)));
  }
  cout << answer << "\n";
  return 0;
}
