#include <bits/stdc++.h>
using namespace std;
set<tuple<int, int, int>> s;
vector<long long> v[200005];
vector<long long> sum1[200005];
long long mod = 1e9 + 7;
long long a[200005];
queue<tuple<long long, long long, long long>> q;
long long ceil1(long long a, long long b) {
  if (a % b != 0)
    return a / b + 1;
  else
    return a / b;
}
long long power(long long a, long long b, long long n) {
  long long ans = 1;
  while (b > 0) {
    if (b % 2 == 1) ans = (ans * a) % n;
    a = (a * a) % n;
    b /= 2;
  }
  return ans;
}
map<string, long long> m1;
map<long long, long long> m;
set<long long> s1[200005];
set<pair<long long, long long>> s2;
set<long long> s3;
pair<long long, long long> p[100005];
long long count1 = 0;
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
int main() {
  ios::sync_with_stdio(0);
  long long n;
  cin >> n;
  for (int i = 0; i < 2 * n; i++) {
    cin >> a[i];
    m[a[i]]++;
  }
  sort(a, a + 2 * n);
  for (int i = 0; i < 2 * n; i++) {
    if (m[a[i]] >= n) {
      cout << 0 << endl;
      return 0;
    }
  }
  long long min1 = LLONG_MAX;
  min1 = min((a[n - 1] - a[0]) * (a[2 * n - 1] - a[n]), min1);
  for (int i = 1; i < n; i++) {
    min1 = min(min1, (a[2 * n - 1] - a[0]) * (a[n + i - 1] - a[i]));
  }
  cout << min1 << endl;
  return 0;
}
