#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long n;
  cin >> n;
  vector<long long> a(2 * n);
  for (long long i = 0; i < n * 2; i++) {
    cin >> a[i];
  }
  sort(a.begin(), a.end());
  long long ans = (a[n - 1] - a[0]) * (a[n * 2 - 1] - a[n]);
  for (long long i = 1; i < n; i++) {
    ans = min(ans, (a[n * 2 - 1] - a[0]) * (a[n + i - 1] - a[i]));
  }
  cout << ans;
  return 0;
}
