#include <bits/stdc++.h>

using namespace std;

const int MOD = 1e9 + 7;

int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n;
  cin >> n;
  int mn_x = 1e9;
  int mn_y = 1e9;
  int mx_x = -1e9;
  int mx_y = -1e9;
  long long sx = 0;
  long long sy = 0;
  vector<long long> f(4);
  for (int t = 1; t <= n; t++) {
    int x, y;
    cin >> x >> y;
    mn_x = min(mn_x, x);
    mn_y = min(mn_y, y);
    mx_x = max(mx_x, x);
    mx_y = max(mx_y, y);
    sx += x;
    sy += y;
    f[0] += x * 1LL * y;
    f[1] -= x * 1LL * y;
    f[2] -= x * 1LL * y;
    f[3] += x * 1LL * y;
    long long ans = 0;
    ans = max(ans, f[0] - mn_y * 1LL * sx - mn_x * 1LL * sy + mn_x * 1LL * mn_y * 1LL * t);
    ans = max(ans, f[1] + mx_x * 1LL * sy + sx * 1LL * mn_y - mx_x * 1LL * mn_y * 1LL * t);
    ans = max(ans, f[2] + mx_y * 1LL * sx + sy * 1LL * mn_x - mx_y * 1LL * mn_x * 1LL * t);
    ans = max(ans, f[3] + mx_x * 1LL * mx_y * 1LL * t - mx_x * 1LL * sy - sx * 1LL * mx_y);
    cout << ans % MOD << '\n';
  }
  return 0;
}