#include <bits/stdc++.h>
using namespace std;
long long n, m, num[300100], tt = 1;
struct Node {
  long long ls, rs, lm, rm, mx, ln, rn, len;
};
Node node[300100 << 1];
inline bool lj(long long u, long long v) {
  return u > 0 && v || u < 0 && v < 0;
}
inline void up(long long now) {
  long long u = node[now].ls, v = node[now].rs;
  if (!u || !v) {
    node[now] = node[u + v];
    return;
  }
  node[now].ln = node[u].ln;
  node[now].rn = node[v].rn;
  node[now].len = node[u].len + node[v].len;
  node[now].mx = max(node[u].mx, node[v].mx);
  if (lj(node[u].rn, node[v].ln)) {
    if (node[u].lm == node[u].len)
      node[now].lm = node[u].lm + node[v].lm;
    else
      node[now].lm = node[u].lm;
    if (node[v].rm == node[v].len)
      node[now].rm = node[v].rm + node[u].rm;
    else
      node[now].rm = node[v].rm;
    node[now].mx = max(node[now].mx, node[u].rm + node[v].lm);
  } else {
    node[now].lm = node[u].lm;
    node[now].rm = node[v].rm;
  }
}
void build(long long now, long long l, long long r) {
  if (l == r) {
    if (num[l]) node[now].lm = node[now].rm = node[now].mx = 1;
    node[now].ln = node[now].rn = num[l];
    node[now].len = 1;
    return;
  }
  if (l <= ((l + r) >> 1)) {
    node[now].ls = ++tt;
    build(tt, l, ((l + r) >> 1));
  }
  if (((l + r) >> 1) < r) {
    node[now].rs = ++tt;
    build(tt, ((l + r) >> 1) + 1, r);
  }
  up(now);
}
void chg(long long now, long long l, long long r, long long u) {
  if (l == r) {
    if (num[u]) node[now].lm = node[now].rm = node[now].mx = 1;
    node[now].ln = node[now].rn = num[u];
    return;
  }
  if (u <= ((l + r) >> 1))
    chg(node[now].ls, l, ((l + r) >> 1), u);
  else
    chg(node[now].rs, ((l + r) >> 1) + 1, r, u);
  up(now);
}
void out(long long now, long long l, long long r) {
  printf("%lld <%lld %lld> {%lld %lld} [%lld %lld] &%lld& |-%lld-|\n", now, l,
         r, node[now].ln, node[now].rn, node[now].lm, node[now].rm,
         node[now].mx, node[now].len);
  if (l == r) return;
  if (l <= ((l + r) >> 1)) out(node[now].ls, l, ((l + r) >> 1));
  if (((l + r) >> 1) < r) out(node[now].rs, ((l + r) >> 1) + 1, r);
}
int main() {
  long long i, j, p, q, o;
  cin >> n;
  for (i = 0; i < n; i++) {
    scanf("%lld", &num[i]);
  }
  n--;
  for (i = n; i >= 1; i--) num[i] -= num[i - 1];
  build(1, 1, n);
  cin >> m;
  for (i = 1; i <= m; i++) {
    scanf("%lld%lld%lld", &p, &q, &o);
    if (p > 1) num[p - 1] += o, chg(1, 1, n, p - 1);
    if (q <= n) num[q] -= o, chg(1, 1, n, q);
    printf("%lld\n", node[1].mx + 1);
  }
}
