#include <bits/stdc++.h>
using namespace std;
vector<pair<long double, int>> v;
string s[2000];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int n;
  cin >> n;
  int ans = 0;
  vector<pair<int, int>> a(n);
  for (int i = 0; i < n; ++i) {
    cin >> a[i].first >> a[i].second;
  }
  for (int i = 0; i < n; ++i)
    for (int j = 0; j < n; ++j)
      ans = max(ans,
                abs((a[i].first - a[j].first) * (a[i].second - a[j].second)));
  if (ans == 0) {
    cout << -1;
    return 0;
  }
  cout << ans;
  return 0;
}
