#include <bits/stdc++.h>
using namespace std;
const long long NMAX = 3e5 + 5;
struct Node {
  int maxLen;
  int leftLen, rightLen;
};
Node segmTree[4 * NMAX];
int n, m;
long long a[NMAX], v[NMAX];
bool cmp(long long x, long long y) {
  if (x == 0 || y == 0) return true;
  int vx = (x > 0) ? (1) : ((x < 0) ? (-1) : 0);
  int vy = (y > 0) ? (1) : ((y < 0) ? (-1) : 0);
  if (vx < vy) return true;
  return false;
}
void recalc(int node, int left, int right) {
  int mid = left + (right - left) / 2;
  segmTree[node].maxLen =
      max(segmTree[2 * node + 1].maxLen, segmTree[2 * node + 2].maxLen);
  segmTree[node].leftLen = segmTree[2 * node + 1].leftLen;
  segmTree[node].rightLen = segmTree[2 * node + 2].rightLen;
  if (cmp(v[mid], v[mid + 1])) return;
  segmTree[node].maxLen =
      max(segmTree[node].maxLen,
          segmTree[2 * node + 1].rightLen + segmTree[2 * node + 2].leftLen);
  if (segmTree[2 * node + 1].leftLen == mid - left + 1)
    segmTree[node].leftLen += segmTree[2 * node + 2].leftLen;
  if (segmTree[2 * node + 2].rightLen == right - mid)
    segmTree[node].rightLen += segmTree[2 * node + 1].rightLen;
}
void build(int node, int left, int right) {
  if (left == right) {
    segmTree[node] = {v[left] != 0, v[left] != 0, v[left] != 0};
    return;
  }
  int mid = left + (right - left) / 2;
  build(2 * node + 1, left, mid);
  build(2 * node + 2, mid + 1, right);
  recalc(node, left, right);
}
void update(int node, int left, int right, int pos, int val) {
  if (left == right) {
    v[left] += val;
    segmTree[node] = {v[left] != 0, v[left] != 0, v[left] != 0};
    return;
  }
  int mid = left + (right - left) / 2;
  if (pos <= mid) {
    update(2 * node + 1, left, mid, pos, val);
  } else {
    update(2 * node + 2, mid + 1, right, pos, val);
  }
  recalc(node, left, right);
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cin >> n;
  for (int i = 1; i <= n; ++i) {
    cin >> a[i];
  }
  for (int i = 1; i <= n - 1; ++i) {
    v[i] = a[i + 1] - a[i];
  }
  if (n != 1) build(0, 1, n - 1);
  cin >> m;
  while (m--) {
    int left, right, d;
    cin >> left >> right >> d;
    if (n == 1) {
      cout << "1\n";
      continue;
    }
    if (left != 1) update(0, 1, n - 1, left - 1, d);
    if (right != n) update(0, 1, n - 1, right, -d);
    cout << 1 + segmTree[0].maxLen << '\n';
  }
  return 0;
}
