#include<bits/stdc++.h>
#define rep(i,a,b)    for(int i=a;i<b;i++)
#define ret(x) return cout<<x,0;
#define rety return cout<<"YES",0;
#define retn return cout<<"NO",0;
typedef long long ll;
typedef double db;
typedef long double ld;
#define stt string
#define ve vector<ll>
#define se set<ll>
#define ar array
ll mod=1e9+7,mod2=998244353;
using namespace std;
ll fac[10000000];
ll gcd(ll x, ll y)
{
   if(y==0)
       return x;
   return gcd(y,x%y);
}
ll fexp(ll a,ll b,ll m){ll ans = 1;while(b){if(b&1)ans=ans*a%m; b/=2;a=a*a%m;}return ans;}
ll inverse(ll a, ll p){return fexp(a, p-2,p);}
ll ncr(ll n, ll r,ll p)
{
   if (r==0) return 1;
   return (fac[n]*inverse(fac[n-r],p)%p*inverse(fac[r],p)%p)%p;
}
// ____Z-Algorithm_____
vector<ll> za(string s)
{
  ll n = s.size();
   vector<ll> z(n);
   ll x = 0, y = 0,p=0;
          for(ll i= 1; i < n; i++)
         {
          z[i] = max(p,min(z[i-x],y-i+1));
        while(i+z[i] < n && s[z[i]] == s[i+z[i]])
             {
              x = i; y = i+z[i]; z[i]++;
             }
         }
return z;
}
void subset(ll a[],ll k)
{
   for (int i = 1; i < pow(2, k); i++)
   {
       for (int j = 0; j < k; j++)
       {
           if (i & 1 << j)
           {
                cout<<a[j]<<" ";
           }
       }
       cout<<endl;
   }
}
vector<ll> pr(string s)
{
   ll n = s.length();
   vector<ll> pi(n);
   for (int i = 1; i < n; i++)
   {
       int j = pi[i-1];
       while (j > 0 && s[i] != s[j])
           j = pi[j-1];
       if (s[i] == s[j])
           j++;
       pi[i] = j;
   }
   return pi;
}
//---------------------------------------------------------------------/
int main()
{
  ios::sync_with_stdio(0);
  cin.tie(0);
  ll t;
  cin>>t;
  while(t--)
  {
    int n;
cin >> n;
vector<int> a(n);
for(int i = 0; i < n; i++) {
    cin >> a[i];
}
cout << 3*n << endl;
 for(int i = 1; i <= n; i+=2)
 {
    cout << 1 << " " << i << " " << i+1 << endl;
    cout << 2 << " " << i << " " << i+1 << endl;
    cout << 2 << " " << i << " " << i+1 << endl;
    cout << 1 << " " << i << " " << i+1 << endl;
    cout << 2 << " " << i << " " << i+1 << endl;
    cout << 2 << " " << i << " " << i+1 << endl;
 }
 }
}
