#include <bits/stdc++.h>
using namespace std;
int mult(int x, int y) {
  long long int ans, x1 = (long long int)x, y1 = (long long int)y;
  ans = (x1 * y1) % 1000000007;
  return (int)ans;
}
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
int lcm(int a, int b) { return a * (b / gcd(a, b)); }
long long int pow1(long long int a, long long int b) {
  long long int ans = 1;
  while (b > 0) {
    if (b & 1) ans = (ans * a) % 1000000007;
    a = (a * a) % 1000000007;
    b >>= 1;
  }
  return ans;
}
int mina(int arr[], int n) {
  int x = arr[0], i, pos = 0;
  for (i = 1; i < n; i++) {
    if (arr[i] < x) {
      x = arr[i];
      pos = i;
    }
  }
  return x;
}
int maxa(int arr[], int n) {
  int x = arr[0], i, pos = 0;
  for (i = 1; i < n; i++) {
    if (arr[i] > x) {
      x = arr[i];
      pos = i;
    }
  }
  return x;
}
long long int arr[300005], a[300005];
struct node {
  int lval, rval, ans;
};
node tree[2000005];
int sign(long long int x) {
  if (x > 0) return 1;
  if (x < 0) return -1;
  return 0;
}
void combine(int pos, int low, int high) {
  int mid = (low + high) >> 1;
  tree[pos].ans = max(tree[2 * pos].ans, tree[2 * pos + 1].ans);
  if (!a[mid] || !a[mid + 1] || sign(a[mid]) < sign(a[mid + 1])) {
    tree[pos].lval = tree[2 * pos].lval;
    tree[pos].rval = tree[2 * pos + 1].rval;
    return;
  }
  tree[pos].ans =
      max(tree[pos].ans, tree[2 * pos].rval + tree[2 * pos + 1].lval);
  if (tree[2 * pos].ans == (mid - low + 1))
    tree[pos].lval = tree[2 * pos].lval + tree[2 * pos + 1].lval;
  else
    tree[pos].lval = tree[2 * pos].lval;
  if (tree[2 * pos + 1].ans == (high - mid))
    tree[pos].rval = tree[2 * pos].rval + tree[2 * pos + 1].rval;
  else
    tree[pos].rval = tree[2 * pos + 1].rval;
}
void build(int pos, int low, int high) {
  if (low == high) {
    int x = !!a[low];
    tree[pos] = {x, x, x};
    return;
  }
  int mid = (low + high) >> 1;
  build(2 * pos, low, mid);
  build(2 * pos + 1, mid + 1, high);
  combine(pos, low, high);
}
void update(int pos, int low, int high, int l, long long int val) {
  if (low == high) {
    a[l] += val;
    int x = !!a[l];
    tree[pos] = {x, x, x};
    return;
  }
  int mid = (low + high) >> 1;
  if (l <= mid)
    update(2 * pos, low, mid, l, val);
  else
    update(2 * pos + 1, mid + 1, high, l, val);
  combine(pos, low, high);
}
int main() {
  int m, n, i, j, k;
  scanf("%d", &n);
  for (i = 1; i < n + 1; i++) scanf("%lld", &arr[i]);
  for (i = 1; i < n; i++) a[i] = arr[i + 1] - arr[i];
  if (n > 1) build(1, 1, n - 1);
  scanf("%d", &m);
  while (m--) {
    int l, r;
    long long int d;
    scanf("%d", &l);
    scanf("%d", &r);
    scanf("%lld", &d);
    if (n == 1) {
      printf("1\n");
      continue;
    }
    if (l != 1) update(1, 1, n - 1, l - 1, d);
    if (r != n) update(1, 1, n - 1, r, -d);
    printf("%d\n", tree[1].ans + 1);
  }
  return 0;
}
