#include <bits/stdc++.h>
using namespace std;
const int maxn = 300055;
long long dif[maxn];
struct SegT {
  int incR[maxn << 2], decL[maxn << 2], ansL[maxn << 2], ansR[maxn << 2],
      ans[maxn << 2];
  void pushup(int l, int r, int rt) {
    int mid = l + r >> 1;
    decL[rt] = decL[rt << 1];
    incR[rt] = incR[rt << 1 | 1];
    ansL[rt] = ansL[rt << 1];
    ansR[rt] = ansR[rt << 1 | 1];
    ans[rt] = max(ans[rt << 1], ans[rt << 1 | 1]);
    if (dif[mid] > 0) {
      ans[rt] = max(ans[rt], ansL[rt << 1 | 1] + incR[rt << 1]);
      if (incR[rt << 1] == mid - l + 1) ansL[rt] += ansL[rt << 1 | 1];
      if (ansR[rt << 1 | 1] == r - mid) ansR[rt] += incR[rt << 1];
      if (incR[rt << 1 | 1] == r - mid) incR[rt] += incR[rt << 1];
    } else if (dif[mid] < 0) {
      ans[rt] = max(ans[rt], ansR[rt << 1] + decL[rt << 1 | 1]);
      if (ansL[rt << 1] == mid - l + 1) ansL[rt] += decL[rt << 1 | 1];
      if (decL[rt << 1 | 1] == r - mid) ansR[rt] += ansR[rt << 1];
      if (decL[rt << 1] == mid - l + 1) decL[rt] += decL[rt << 1 | 1];
    }
    return;
  }
  void build(int l, int r, int rt) {
    if (l == r) {
      incR[rt] = decL[rt] = ans[rt] = ansL[rt] = ansR[rt] = 1;
      return;
    }
    int mid = l + r >> 1;
    build(l, mid, rt << 1);
    build(mid + 1, r, rt << 1 | 1);
    pushup(l, r, rt);
  }
  void update(int x, int l, int r, int rt) {
    if (l == r) return;
    int mid = l + r >> 1;
    if (x <= mid)
      update(x, l, mid, rt << 1);
    else
      update(x, mid + 1, r, rt << 1 | 1);
    pushup(l, r, rt);
  }
  int ask() { return ans[1]; }
} t;
int n, m;
long long a[maxn];
int main() {
  scanf("%d", &n);
  for (int i = 1; i < (n + 1); ++i) scanf("%lld", &a[i]);
  for (int i = 1; i < (n); ++i) dif[i] = a[i + 1] - a[i];
  t.build(1, n, 1);
  scanf("%d", &m);
  while (m--) {
    int l, r;
    long long x;
    scanf("%d %d %lld", &l, &r, &x);
    dif[l - 1] += x;
    dif[r] -= x;
    t.update(l - 1, 1, n, 1);
    t.update(r + 1, 1, n, 1);
    printf("%d\n", t.ask());
  }
}
