#include <bits/stdc++.h>
using namespace std;
const long long MAXN = 3e3 + 20, mod = 0;
long long n, a[MAXN];
vector<string> ans;
void Read_input() {
  cin >> n;
  for (long long i = 1; i <= n; i++) cin >> a[i];
}
void solve() {
  bool flag = true;
  cout << n + 1 << endl;
  for (long long i = n; i > 0; i--) {
    long long r = a[i] % n;
    if (i - 1 > r)
      r = i - 1 - r;
    else
      r = n + i - 1 - r;
    cout << "1 " << i << " " << r << endl;
    for (long long j = 1; j <= i; j++) a[j] += r;
  }
  cout << "2 " << n << " " << n << endl;
}
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  Read_input(), solve();
  return 0;
}
