#include <bits/stdc++.h>
#define here cerr<<"==========================================\n"
#define dbg(x) cerr<<#x<<": "<<x<<endl;
#define ll long long
#define endl '\n'
#define sz(a) (ll)(a.size())
#define fi first
#define sc second
#define pll pair<ll,ll>
#define llinf 1000000000LL
#define pb push_back
using namespace std;
#define maxn 1000005
ll n;
pll a[maxn];
ll sumxy = 0;
ll sumx = 0;
ll sumy = 0;
int main()
{
    ios_base::sync_with_stdio(0); cout.tie(0); cin.tie(0); cerr.tie(0);
    cin >> n;
    ll xl = llinf,xr = -llinf;
    ll yl = llinf,yr = -llinf;
    for(ll i = 1;i<=n;i++){
        ll x,y; cin >> x >> y;
        sumx+=x;
        sumy+=y;
        sumxy+=x*y;
        xl = min(x,xl);
        xr = max(x,xr);
        yl = min(y,yl);
        yr = max(y,yr);
        ll ans = 0;
        ans = max(ans,sumxy-sumy*xl-sumx*yl+i*xl*yl);
        ans = max(ans,sumxy-sumy*xr-sumx*yr+i*xr*yr);
        ans = max(ans,-(sumxy-sumy*xr-sumx*yl+i*xr*yl));
        ans = max(ans,-(sumxy-sumy*xl-sumx*yr+i*xl*yr));
        cout<<ans<<endl;
    }
    return 0;
}