#include<bits/stdc++.h>
#define ll long long int
using namespace std;
void solve(){
	int n;cin>>n;
	vector<ll> arr(n);
	for(int i=0;i<n;i++){
		cin>>arr[i];
	}
	cout<<6*n/2<<endl;
	for(int i=0;i<n;i+=2){
		cout<<"1 "<<i+1<<" "<<i+2<<endl;
		cout<<"2 "<<i+1<<" "<<i+2<<endl;
		cout<<"1 "<<i+1<<" "<<i+2<<endl;
		cout<<"1 "<<i+1<<" "<<i+2<<endl;
		cout<<"2 "<<i+1<<" "<<i+2<<endl;
		cout<<"1 "<<i+1<<" "<<i+2<<endl;
	}
}
int main(){
	int t;cin>>t;
	while(t--){
		solve();
	}
}