#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  int x[5], y[5];
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d %d", &x[i], &y[i]);
  }
  int ans = 0;
  for (int i = 0; i < n; i++) {
    for (int j = i + 1; j < n; j++) {
      int dx = abs(x[i] - x[j]);
      int dy = abs(y[i] - y[j]);
      ans = max(ans, dx * dy);
    }
  }
  if (ans == 0)
    puts("-1");
  else
    printf("%d\n", ans);
}
