<image>

While trading on his favorite exchange trader William realized that he found a vulnerability. Using this vulnerability he could change the values of certain internal variables to his advantage. To play around he decided to change the values of all internal variables from a_1, a_2, …, a_n to -a_1, -a_2, …, -a_n. For some unknown reason, the number of service variables is always an even number.

William understands that with his every action he attracts more and more attention from the exchange's security team, so the number of his actions must not exceed 5 000 and after every operation no variable can have an absolute value greater than 10^{18}. William can perform actions of two types for two chosen variables with indices i and j, where i < j:

  1. Perform assignment a_i = a_i + a_j 
  2. Perform assignment a_j = a_j - a_i 

William wants you to develop a strategy that will get all the internal variables to the desired values.

Input

Each test contains multiple test cases. The first line contains the number of test cases t (1 ≤ t ≤ 20). Description of the test cases follows.

The first line of each test case contains a single even integer n (2 ≤ n ≤ 10^3), which is the number of internal variables.

The second line of each test case contains n integers a_1, a_2, …, a_n (1 ≤ a_i ≤ 10^9), which are initial values of internal variables.

Output

For each test case print the answer in the following format:

The first line of output must contain the total number of actions k, which the strategy will perform. Note that you do not have to minimize k. The inequality k ≤ 5 000 must be satisfied. 

Each of the next k lines must contain actions formatted as "type i j", where "type" is equal to "1" if the strategy needs to perform an assignment of the first type and "2" if the strategy needs to perform an assignment of the second type. Note that i < j should hold.

We can show that an answer always exists.

Example

Input


2
4
1 1 1 1
4
4 3 1 2


Output


8
2 1 2
2 1 2
2 1 3
2 1 3
2 1 4
2 1 4
1 1 2
1 1 2
8
2 1 4
1 2 4
1 2 4
1 2 4
1 3 4
1 1 2
1 1 2
1 1 4

Note

For the first sample test case one possible sequence of operations is as follows:

  1. "2 1 2". Values of variables after performing the operation: [1, 0, 1, 1] 
  2. "2 1 2". Values of variables after performing the operation: [1, -1, 1, 1] 
  3. "2 1 3". Values of variables after performing the operation: [1, -1, 0, 1] 
  4. "2 1 3". Values of variables after performing the operation: [1, -1, -1, 1] 
  5. "2 1 4". Values of variables after performing the operation: [1, -1, -1, 0] 
  6. "2 1 4". Values of variables after performing the operation: [1, -1, -1, -1] 
  7. "1 1 2". Values of variables after performing the operation: [0, -1, -1, -1] 
  8. "1 1 2". Values of variables after performing the operation: [-1, -1, -1, -1] 



For the second sample test case one possible sequence of operations is as follows:

  1. "2 1 4". Values of variables after performing the operation: [4, 3, 1, -2] 
  2. "1 2 4". Values of variables after performing the operation: [4, 1, 1, -2] 
  3. "1 2 4". Values of variables after performing the operation: [4, -1, 1, -2] 
  4. "1 2 4". Values of variables after performing the operation: [4, -3, 1, -2] 
  5. "1 3 4". Values of variables after performing the operation: [4, -3, -1, -2] 
  6. "1 1 2". Values of variables after performing the operation: [1, -3, -1, -2] 
  7. "1 1 2". Values of variables after performing the operation: [-2, -3, -1, -2] 
  8. "1 1 4". Values of variables after performing the operation: [-4, -3, -1, -2] 
2
4
1 1 1 1
4
4 3 1 2

12
1 1 2
2 1 2
1 1 2
2 1 2
1 1 2
2 1 2
1 3 4
2 3 4
1 3 4
2 3 4
1 3 4
2 3 4
12
1 1 2
2 1 2
1 1 2
2 1 2
1 1 2
2 1 2
1 3 4
2 3 4
1 3 4
2 3 4
1 3 4
2 3 4

/*
                                       "जय श्री कृष्णा"
*/
import java.util.*;
import java.io.*;

public class Sol implements Runnable
{

    static class FastReader
    {
        BufferedReader br;
        StringTokenizer st;

        public FastReader()
        {
            this.br = new BufferedReader(new InputStreamReader(System.in));
        }
        public FastReader(String s)
        {
            try
            {
                this.br = new BufferedReader(new FileReader(s));
            }
            catch (FileNotFoundException e)
            {
                e.printStackTrace();
            }
        }

        String next()
        {
            while (st == null || !st.hasMoreElements())
            {
                try
                {
                    st = new StringTokenizer(br.readLine());
                }
                catch (IOException e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt()
        {
            return Integer.parseInt(next());
        }

        long nextLong()
        {
            return Long.parseLong(next());
        }

        double nextDouble()
        {
            return Double.parseDouble(next());
        }

        String nextLine()
        {
            String str = "";
            try
            {
                str = br.readLine();
            }
            catch (IOException e)
            {
                e.printStackTrace();
            }
            return str;
        }

        int[] nextIntArray(int size)
        {
            int[] arr = new int[size];
            for (int i = 0; i < size; ++i)
                arr[i] = nextInt();
            return arr;
        }

        long[] nextLongArray(int size)
        {
            long[] arr = new long[size];
            for (int i = 0; i < size; ++i)
                arr[i] = nextLong();
            return arr;
        }

        double[] nextDoubleArray(int size)
        {
            double[] arr = new double[size];
            for (int i = 0; i < size; ++i)
                arr[i] = nextDouble();
            return arr;
        }
    }
    static class FastWriter
    {
        PrintWriter pw;

        public FastWriter()
        {
            this.pw = (new PrintWriter(new BufferedOutputStream(System.out)));
        }

        public FastWriter(String s)
        {
            try
            {
                this.pw = new PrintWriter(new File(s));
            }
            catch (FileNotFoundException e)
            {
                e.printStackTrace();
            }
        }

        public void print(Object object)
        {
            pw.append("" + object);
        }

        public void println(Object object)
        {
            print(object);
            pw.append("\n");
        }

        public void println()
        {
            pw.append("\n");
        }

        public void close()
        {
            pw.close();
        }

        public void flush()
        {
            pw.flush();
        }

    }


    static int mod = (int) (1e9 + 7), N = (int) (1e5), INF = Integer.MAX_VALUE, NINF = Integer.MIN_VALUE;
    static final FastReader fr = new FastReader();
    static final FastWriter out = new FastWriter();
    public static void main(String[] args) throws java.lang.Exception
    {
        new Thread(null, new Sol(), "Main", 1 << 26).start();
    }

    void solve()
    {

        int n = fr.nextInt();
        int a[] = fr.nextIntArray(n);

        out.println(6 * (n / 2));

        for(int i = 1; i <= n; i += 2)
        {
            for(int j = 0; j < 2; ++j)
            {
                out.println("2 " + (i) + " " + (i + 1));
                out.println("1 " + (i) + " " + (i + 1));
                out.println("2 " + (i) + " " + (i + 1));
            }
        }

    }
    @Override
    public void run()
    {
        long start = System.nanoTime(); // Program Start
        boolean testcase = true;
        int t = testcase ? fr.nextInt() : 1;
        while (t-- > 0)
        {
            solve();
            out.print("\n");
            out.flush();
        }
        out.close();
        long end = System.nanoTime(); // Program End

    }


    static class CP
    {

        static boolean isPrime(long n)
        {
            if (n <= 1)
                return false;
            if (n == 2 || n == 3)
                return true;
            if (n % 2 == 0 || n % 3 == 0)
                return false;
            for (int i = 5; i * i <= n; i += 6)
            {
                if (n % i == 0 || n % (i + 2) == 0)
                    return false;
            }
            return true;
        }
        static List<Integer> sieve(int size)
        {
            ArrayList<Integer> pr = new ArrayList<Integer>();
            boolean prime[] = new boolean[size];
            for(int i = 2; i < prime.length; i++)  prime[i] = true;
            for(int i = 2; i * i < prime.length; i++)
            {
                if(prime[i])
                {
                    for(int j = i * i; j < prime.length; j += i)
                    {
                        prime[j] = false;
                    }
                }
            }
            for(int i = 2; i < prime.length; i++) if(prime[i]) pr.add(i);
            return pr;
        }

        static long binary_Expo(long a, long b)   // calculating a^b
        {
            long res = 1;
            while (b != 0)
            {
                if ((b & 1) == 1)
                {
                    res *= a;
                    --b;
                }
                a *= a;
                b /= 2;
            }
            return res;
        }

        static long Modular_Expo(long a, long b)
        {
            long res = 1;
            while (b != 0)
            {
                if ((b & 1) == 1)
                {
                    res = (res * a) % mod;
                    --b;
                }
                a = (a * a) % mod;
                b /= 2;
            }
            return res;
        }

        static int i_gcd(int a, int b)  // iterative way to calculate gcd.
        {
            while (true)
            {
                if (b == 0)
                    return a;
                int c = a;
                a = b;
                b = c % b;
            }
        }

        static long gcd(long a, long b)  // here b is the remainder
        {
            if (b == 0)
                return a; //because each time b will divide a.
            return gcd(b, a % b);
        }

        static long ceil_div(long a, long b)   // a numerator b denominator
        {
            return (a + b - 1) / b;
        }

        static int getIthBitFromInt(int bits, int i)
        {
            return (bits >> (i - 1)) & 1;
        }

        static int upper_Bound(int a[], int x)  //closest to the left+1
        {
            int l = -1, r = a.length;
            while (l + 1 < r)
            {
                int m = (l + r) >>> 1;
                if (a[m] <= x)
                    l = m;
                else
                    r = m;
            }
            return l + 1;
        }

        static int lower_Bound(int a[], int x)  //closest to the right
        {
            int l = -1, r = a.length;
            while (l + 1 < r)
            {
                int m = (l + r) >>> 1;
                if (a[m] >= x)
                    r = m;
                else
                    l = m;
            }
            return r;
        }
        static boolean isSquarefactor(int x, int factor, int target)
        {
            int s = (int)Math.round(Math.sqrt(x));
            return factor * s * s == target;
        }

        static boolean isSquare(int x)
        {
            int s = (int)Math.round(Math.sqrt(x));
            return x * x == s;
        }
        static void sort(int a[])
        {
            PriorityQueue<Integer> q = new PriorityQueue<>();
            for (int i = 0; i < a.length; i++)
                q.add(a[i]);
            for (int i = 0; i < a.length; i++)
                a[i] = q.poll();
        }

        static int getMax(int arr[], int n)
        {
            int mx = arr[0];
            for (int i = 1; i < n; i++)
                if (arr[i] > mx)
                    mx = arr[i];
            return mx;
        }
        static int[] z_function(String s)
        {
            int n = s.length(), z[] = new int[n];

            for(int i = 1, l = 0, r = 0; i < n; ++i)
            {
                if(i <= r)
                    z[i] = Math.min(z[i - l], r - i + 1);

                while(i + z[i] < n && s.charAt(z[i]) == s.charAt(i + z[i]))
                    ++z[i];

                if(i + z[i] - 1 > r)
                {
                    l = i;
                    r = i + z[i] - 1;
                }
            }
            return z;
        }
        static int [] kmp(String s)
        {
            int n = s.length(), pi[] = new int[n];
            for(int i = 1; i < n; ++i)
            {
                int j = pi[i - 1];

                while(j > 0 && s.charAt(i) != s.charAt(j))
                    j = pi[j - 1];

                if(s.charAt(i) == s.charAt(j))
                    ++j;

                pi[i] = j;

            }

            return pi;
        }
    }

}

