Problem: One winter evening the Hedgehog was relaxing at home in his cozy armchair and clicking through the TV channels. Stumbled on an issue of «TopShop», the Hedgehog was about to change the channel when all of a sudden he was stopped by an advertisement of a new wondrous invention.

Actually, a vacuum cleaner was advertised there. It was called Marvellous Vacuum and it doesn't even need a human to operate it while it cleans! The vacuum cleaner can move around the flat on its own: it moves in some direction and if it hits an obstacle there, it automatically chooses a new direction. Sooner or later this vacuum cleaner will travel through all the room and clean it all. Having remembered how much time the Hedgehog spends every time on cleaning (surely, no less than a half of the day), he got eager to buy this wonder.

However, the Hedgehog quickly understood that the cleaner has at least one weak point: it won't clean well in the room's corners because it often won't able to reach the corner due to its shape. To estimate how serious is this drawback in practice, the Hedgehog asked you to write for him the corresponding program.

You will be given the cleaner's shape in the top view. We will consider only the cases when the vacuum cleaner is represented as a convex polygon. The room is some infinitely large rectangle. We consider one corner of this room and want to find such a rotation of the vacuum cleaner so that it, being pushed into this corner, will leave the minimum possible area in the corner uncovered.

Input

The first line contains an integer N which represents the number of vertices of the vacuum cleaner's polygon (3 ≤ N ≤ 4·104). Then follow N lines each containing two numbers — the coordinates of a vertex of the polygon. All the coordinates are integer and their absolute values do not exceed 106.

It is guaranteed that the given polygon is nondegenerate and convex (no three points lie on the same line). The polygon vertices are given in a clockwise or counter-clockwise direction.

Output

Print the minimum possible uncovered area. The answer will be accepted if it is within 10 - 6 of absolute or relative error from the correct answer.

Examples

Input

4
0 0
1 0
1 1
0 1


Output

0.00000000000000000000

Input

8
1 2
2 1
2 -1
1 -2
-1 -2
-2 -1
-2 1
-1 2


Output

0.50000000000000000000

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
template <typename T>
inline T abs(T a) {
  return ((a < 0) ? -a : a);
}
template <typename T>
inline T sqr(T a) {
  return a * a;
}
const int INF = (int)1E9 + 7;
const long double EPS = 1E-9;
const long double PI = 3.1415926535897932384626433832795;
const int NMAX = 100000;
pair<int, int> a[NMAX];
int n;
long long sum[NMAX];
pair<int, int> operator-(const pair<int, int>& a, const pair<int, int>& b) {
  return pair<int, int>(a.first - b.first, a.second - b.second);
}
long long smul(const pair<int, int>& a, const pair<int, int>& b) {
  return a.first * 1LL * b.first + a.second * 1LL * b.second;
}
long long vmul(const pair<int, int>& a, const pair<int, int>& b) {
  return a.first * 1LL * b.second - a.second * 1LL * b.first;
}
long long area(const pair<int, int>& a, const pair<int, int>& b,
               const pair<int, int>& c) {
  return abs(vmul(b - a, c - a));
}
inline long long getSum(int lf, int rg) {
  if (lf > rg) return 0;
  return sum[rg] - (lf == 0 ? 0 : sum[lf - 1]);
}
long long getArea(int lf, int rg) {
  if (lf == rg) return 0;
  long long ans = 0;
  if (lf < rg) {
    ans = getSum(lf, rg - 1);
    ans -= area(a[0], a[lf], a[rg]);
  } else {
    ans = getSum(lf, n - 2) + getSum(0, rg - 1) + area(a[0], a[lf], a[rg]);
  }
  return ans;
}
const int dx[] = {1, -1};
inline bool move(int& it, const pair<int, int>& v) {
  long long C = -smul(a[it], v);
  for (int i = 0; i < int(2); ++i) {
    int nit = it + dx[i];
    while (nit >= n) nit -= n;
    while (nit < 0) nit += n;
    long long curC = -smul(a[nit], v);
    if (curC < C) {
      it = nit;
      return true;
    }
  }
  return false;
}
long double ans = 1E100;
long double dist(const pair<int, int>& a, const pair<int, int>& b,
                 const pair<int, int>& v) {
  long long C1 = -smul(a, v), C2 = -smul(b, v);
  return abs(C1 - C2) / sqrtl((sqr(v.first * 1LL) + sqr(v.second * 1LL)) * 1.0);
}
void updAns(int i, int j, const pair<int, int>& v) {
  long long S = getArea(i, j);
  long double dx = dist(a[i], a[j], v);
  long double dy = dist(a[i], a[j], pair<int, int>(-v.second, v.first));
  long double cur = dx * dy * 0.5 - S * 0.5;
  ans = min(ans, cur);
}
int main() {
  scanf("%d", &n);
  for (int i = 0; i < int(n); ++i) scanf("%d%d", &a[i].first, &a[i].second);
  for (int i = int(1); i < int(n - 1); ++i) {
    sum[i] = area(a[0], a[i], a[i + 1]);
    if (i > 0) sum[i] += sum[i - 1];
  }
  int iup = 0, idown = 0;
  for (int i = 0; i < int(n); ++i) {
    pair<int, int> cp = a[i], np = a[i + 1 == n ? 0 : i + 1];
    pair<int, int> v = np - cp;
    while (move(iup, v))
      ;
    updAns(i, iup, v);
    v = cp - np;
    while (move(idown, v))
      ;
    updAns(idown, i, v);
  }
  cout.precision(10);
  cout << fixed << ans << endl;
  return 0;
}