#include <bits/stdc++.h>
using namespace std;
int32_t main() {
  long long n;
  cin >> n;
  vector<long long> a(n * 2);
  for (int i = 0; i < n * 2; i++) cin >> a[i];
  sort(a.begin(), a.end());
  long long ans = (a[n - 1] - a[0]) * (a.back() - a[n]);
  for (int i = 1; i < n; i++)
    ans = min(ans, (a.back() - a[0]) * (a[i + n - 1] - a[i]));
  for (int i = n; i < n * 2; i++)
    ans = min(ans, (a[i] - a[0]) * (a.back() - a[min((long long)i - 1, n)]));
  cout << ans;
}
