#include <bits/stdc++.h>

using namespace std;

struct tacka{
    int x;
    int y;
};

tacka niz[100100];

long long povrsinaTrougla(tacka a, tacka b, tacka c){
    double AB = sqrt(abs(a.x - b.x)*abs(a.x - b.x) + abs(a.y - b.y)*abs(a.y - b.y));
    double AC = sqrt(abs(a.x - c.x)*abs(a.x - c.x) + abs(a.y - c.y)*abs(a.y - c.y));
    double CB = sqrt(abs(c.x - b.x)*abs(c.x - b.x) + abs(c.y - b.y)*abs(c.y - b.y));
    double s = (AB + AC + CB)/2;
    int rez = sqrt(s*(s-AB)*(s-AC)*(s-CB));
    return rez;
}

int main()
{
    ios::sync_with_stdio(0);
    cin.tie(0);
    long long n = 0, ukupnaPov = 0, maxTrougao = 0;
    cin >> n;
    for(int i = 0; i < n; i++){
        cin >> niz[i].x >> niz[i].y;
    }
    if(n == 4){
        cout << min(min(povrsinaTrougla(niz[0], niz[1], niz[2]), povrsinaTrougla(niz[0], niz[1], niz[3])), min(povrsinaTrougla(niz[0], niz[2], niz[3]), povrsinaTrougla(niz[1], niz[2], niz[3])));
    }
    else{
        for(int i = 0; i < n-1; i++){
            ukupnaPov += (niz[i+1].x-niz[i].x)*(niz[i].y+niz[i+1].y)/2;
        }
        ukupnaPov += (niz[0].x-niz[n-1].x)*(niz[n-1].y+niz[0].y)/2;
        for(int i = 1; i < n-1; i++){
            if(povrsinaTrougla(niz[i-1], niz[i], niz[i+1]) > maxTrougao){
                maxTrougao = povrsinaTrougla(niz[i-1], niz[i], niz[i+1]);
            }
        }
        if(povrsinaTrougla(niz[n-2], niz[n-1], niz[0]) > maxTrougao){
            maxTrougao = povrsinaTrougla(niz[n-1], niz[n], niz[n+1]);
        }
        if(povrsinaTrougla(niz[n-1], niz[0], niz[1]) > maxTrougao){
            maxTrougao = povrsinaTrougla(niz[n-1], niz[n], niz[n+1]);
        }
        cout << ukupnaPov- maxTrougao;
    }
    return 0;
}