#include <bits/stdc++.h>
using namespace std;
void solve(long long int T) {
  long long int n;
  cin >> n;
  vector<long long int> arr(n + 1);
  for (long long int i = 1; i <= n; i++) {
    cin >> arr[i];
  }
  long long int val = 5e5;
  for (long long int i = 1; i <= n; i++) {
    arr[i] += val;
  }
  cout << n + 1 << endl;
  cout << "1 " << n << " " << val << endl;
  ;
  for (long long int i = 1; i <= n; i++) {
    cout << 2 << " " << i << " " << arr[i] - i << endl;
  }
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long int T = 1;
  for (long long int t = 1; t <= T; t++) {
    solve(t);
  }
  cerr << "time taken : " << (float)clock() / CLOCKS_PER_SEC << " secs" << endl;
  return 0;
}
