#include <bits/stdc++.h>
using namespace std;
inline bool eq(double a, double b) { return fabs(a - b) < 1e-9; }
const int inf = 1 << 29;
inline int two(int n) { return 1 << n; }
inline int test(int n, int b) { return (n >> b) & 1; }
inline void set_bit(int& n, int b) { n |= two(b); }
inline void unset_bit(int& n, int b) { n &= ~two(b); }
inline int last_bit(int n) { return n & (-n); }
inline int ones(int n) {
  int res = 0;
  while (n && ++res) n -= n & (-n);
  return res;
}
int ar[100002];
vector<pair<int, pair<int, int> > > op;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  for (int i = (0); i < (n); i++) {
    cin >> ar[i];
  }
  cout << n + 1 << endl;
  for (int i = (n - 1); i >= (0); i--) {
    int rem = ar[i] % (n + 1);
    rem = n + 1 - rem + i + 1;
    cout << "1 " << i + 1 << " " << rem << endl;
    for (int j = (0); j <= (i); j++) {
      ar[j] += rem;
    }
  }
  cout << "2 " << n << " " << n + 1 << endl;
  return 0;
}
