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