#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7, N = 1e6 + 1;
int main() {
  long long n;
  cin >> n;
  long long arr[n];
  for (long long i = 0; i < n; i++) cin >> arr[i];
  cout << n + 1 << endl;
  for (long long i = n - 1; i >= 0; i--) {
    long long p = arr[i];
    long long fact = p / n;
    fact = (n) * (fact + 1);
    fact = fact + (i);
    for (long long j = 0; j < i; j++) arr[j] = arr[j] + fact - p;
    cout << 1 << " " << i + 1 << " " << fact - p << endl;
  }
  cout << 2 << " " << n << " " << n;
  return 0;
}
