#include <bits/stdc++.h>
using namespace std;
vector<long long> v;
long long n, i, a[200005], sum, act, targ;
int main() {
  cin >> n;
  for (i = 1; i <= n; i++) {
    cin >> a[i];
  }
  act = 100000 - 1;
  sum = 0;
  for (i = n; i >= 1; i--) {
    a[i] += sum;
    targ = (a[i] / 100000 + 1) * 100000 + act - a[i];
    v.push_back(targ);
    act--;
    sum += targ;
  }
  cout << n + 1 << '\n';
  for (i = 0; i < n; i++) {
    cout << 1 << ' ' << n - i << ' ' << v[i] << '\n';
  }
  cout << "2 " << n << ' ' << 100000 << '\n';
  return 0;
}
