#include <bits/stdc++.h>
using namespace std;
int arr[2001];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &arr[i]);
    arr[i] += 500000;
  }
  printf("%d\n", n + 1);
  printf("1 %d 500000\n", n);
  for (int i = 0; i < n; i++) {
    printf("2 %d %d\n", i + 1, arr[i] - i);
  }
  return 0;
}
