#include <bits/stdc++.h>
using namespace std;
const int MAX = 2e5 + 5;
long long a[MAX];
int main() {
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) scanf("%lld", a + i);
  printf("%d\n", n + 1);
  printf("1 %d 500000\n", n);
  for (int i = 1; i <= n; i++) a[i] += 500000;
  for (int i = 1; i <= n; i++) {
    printf("2 %d %lld\n", i, a[i] - i);
  }
  return 0;
}
