#include <bits/stdc++.h>
void fre() { freopen("in.txt", "r", stdin); }
void freout() { freopen("out.txt", "w", stdout); }
inline int read() {
  int x = 0, f = 1;
  char ch = getchar();
  while (ch > '9' || ch < '0') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
using namespace std;
struct node {
  int l, m, r;
};
node t[3000005];
int arr[300005], n, m;
long long a[300005];
int sign(long long x) {
  if (x > 0) return 1;
  if (x < 0) return -1;
  return 0;
}
void cal(int x, int l, int r) {
  int m = (l + r) / 2;
  t[x].m = max(t[x * 2].m, t[x * 2 + 1].m);
  t[x].l = t[x * 2].l;
  t[x].r = t[x * 2 + 1].r;
  if (!!a[m] && !!a[m + 1] && sign(a[m]) >= sign(a[m + 1])) {
    t[x].m = max(t[x].m, t[x * 2].r + t[x * 2 + 1].l);
    if (t[2 * x].m == m - l + 1) t[x].l = t[2 * x].m + t[2 * x + 1].l;
    if (t[2 * x + 1].m == r - m) t[x].r = t[2 * x].r + t[2 * x + 1].m;
  }
}
void build(int x, int l, int r) {
  if (l == r) {
    int tmp = !!a[l];
    t[x] = {tmp, tmp, tmp};
    return;
  }
  int m = (l + r) / 2;
  build(x * 2, l, m);
  build(x * 2 + 1, m + 1, r);
  cal(x, l, r);
}
void update(int x, int l, int r, int pos, int d) {
  if (l == r) {
    a[pos] += d;
    int tmp = !!a[pos];
    t[x] = {tmp, tmp, tmp};
    return;
  }
  int m = (l + r) / 2;
  if (pos <= m)
    update(x * 2, l, m, pos, d);
  else
    update(x * 2 + 1, m + 1, r, pos, d);
  cal(x, l, r);
}
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) scanf("%d", &arr[i]);
  for (int i = 0; i + 1 < n; i++) a[i] = arr[i + 1] - arr[i];
  if (n > 1) build(1, 0, n - 2);
  cin >> m;
  while (m--) {
    int l, r, d;
    scanf("%d%d%d", &l, &r, &d);
    if (n == 1) {
      printf("%d\n", 1);
      continue;
    }
    if (l > 1) update(1, 0, n - 2, l - 2, d);
    if (r < n) update(1, 0, n - 2, r - 1, -d);
    printf("%d\n", t[1].m + 1);
  }
  return 0;
}
