#include <bits/stdc++.h>
using namespace std;
const int N = 1e4 + 10;
int n, x[4], y[4];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cin >> n;
  for (int i = 0; i < n; ++i) cin >> x[i] >> y[i];
  sort(x, x + n);
  sort(y, y + n);
  if (n == 1 || y[n - 1] == y[0] || x[n - 1] == x[0])
    cout << -1 << '\n';
  else
    cout << (y[n - 1] - y[0]) * (x[n - 1] - x[0]) << '\n';
  return 0;
}
