/*
* Do smth instead of nothing and stay organized
*/

#include <bits/stdc++.h>
using namespace std;

#define forn(i, n) for (int i = 0; i < (int)(n); i++)
#define all(a) (a).begin(), (a).end()
#define pb push_back
#define x first
#define y second

void solve() {
    int n, x; cin >> n;
    forn (i, n) cin >> x;
    cout << 3 * n << '\n';
    forn (i, n) {
        forn (_, 3) {
            cout << 1 << ' '  << i + 1 << ' ' << i + 2 << '\n';
            cout << 2 << ' '  << i + 1 << ' ' << i + 2 << '\n';
        }
        i++;
    }
}

int main(){
    ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
    int t; cin >> t;
    for (; t; t--) {
        solve();
    }
}