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;
long long cross(pair<int, int> a, pair<int, int> b) {
  return 1LL * a.first * b.second - 1LL * a.second * b.first;
}
long long ccw(pair<int, int> a, pair<int, int> b, pair<int, int> c) {
  pair<int, int> p = pair<int, int>(b.first - a.first, b.second - a.second);
  pair<int, int> q = pair<int, int>(c.first - a.first, c.second - a.second);
  return cross(p, q);
}
long long dot(pair<int, int> a, pair<int, int> b) {
  return 1LL * a.first * b.first + 1LL * a.second * b.second;
}
double dist(pair<int, int> a, pair<int, int> b) {
  int dx = a.first - b.first;
  int dy = a.second - b.second;
  return sqrt(1LL * dx * dx + 1LL * dy * dy);
}
int N;
pair<int, int> P[40010];
long long psum[80010];
long long area(int l, int r) {
  if (l > r) r += N;
  if (l == 0) l += N, r += N;
  return abs(psum[r - 1] - psum[l - 1] + cross(P[r % N], P[l % N]));
}
double calc(int l, int r) {
  int m = (l + 1) % N;
  double c = dist(P[l], P[r]);
  pair<int, int> p =
      pair<int, int>(P[m].first - P[l].first, P[m].second - P[l].second);
  pair<int, int> q =
      pair<int, int>(P[r].first - P[l].first, P[r].second - P[l].second);
  double Cos = (double)dot(p, q) / dist(pair<int, int>(0, 0), p) /
               dist(pair<int, int>(0, 0), q);
  double Sin = (double)cross(p, q) / dist(pair<int, int>(0, 0), p) /
               dist(pair<int, int>(0, 0), q);
  return c * c * Cos * abs(Sin);
}
double ans;
void solve() {
  for (int i = 0; i < 2 * N; i++) {
    psum[i] = cross(P[i % N], P[(i + 1) % N]);
    if (i) psum[i] += psum[i - 1];
  }
  int pos = 1;
  for (int i = 0; i < N; i++) {
    int j = (i + 1) % N;
    while (1) {
      int nxt = (pos + 1) % N;
      pair<int, int> p =
          pair<int, int>(P[i].first - P[j].first, P[i].second - P[j].second);
      pair<int, int> q = pair<int, int>(P[nxt].first - P[pos].first,
                                        P[nxt].second - P[pos].second);
      if (dot(p, q) >= 0)
        break;
      else
        pos = nxt;
    }
    double tmp = calc(i, pos) - area(i, pos);
    ans = min(ans, tmp);
  }
}
int main() {
  scanf("%d", &N);
  for (int i = 0; i < N; i++) {
    scanf("%d %d", &P[i].first, &P[i].second);
  }
  for (int i = 0; i < N; i++) {
    int j = (i + 1) % N;
    int k = (i + 2) % N;
    pair<int, int> p =
        pair<int, int>(P[i].first - P[j].first, P[i].second - P[j].second);
    pair<int, int> q =
        pair<int, int>(P[k].first - P[j].first, P[k].second - P[j].second);
    if (dot(p, q) >= 0) {
      printf("0");
      return 0;
    }
  }
  ans = 1e18;
  solve();
  reverse(P, P + N);
  solve();
  ans /= 2;
  cout << fixed;
  cout.precision(20);
  cout << ans;
}