#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, x1, x2, x3, x4, y1, y2, y3, y4, l, b;
  long long int area = 0;
  cin >> n;
  if (n == 1) {
    cout << -1 << endl;
    return 0;
  }
  if (n == 2) {
    cin >> x1 >> y1 >> x2 >> y2;
    if ((x1 == x2) || (y1 == y2)) {
      cout << -1 << endl;
      return 0;
    } else {
      area = (x1 - x2) * (y1 - y2);
      if (area < 0) {
        area = area * -1;
      }
    }
  } else if ((n == 3) || (n == 4)) {
    cin >> x1 >> y1 >> x2 >> y2 >> x3 >> y3;
    if (x1 != x2) {
      l = x1 - x2;
    } else {
      l = x1 - x3;
    }
    if (y1 != y2) {
      b = y1 - y2;
    } else {
      b = y1 - y3;
    }
    area = l * b;
    if (area < 0) {
      area = area * -1;
    }
  }
  if (n == 4) cin >> x4 >> y4;
  cout << area << endl;
  return 0;
}
