#include <bits/stdc++.h>
#include <string>
#include <cstdint>
#include <iterator>
#include <algorithm>
#include <fstream>
#include <vector>
#include <set>

using namespace std;

using ll = long long;
using ld = long double;

#define FAST_IO ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
#define Int int_fast64_t
#define pb push_back
#define mp make_pair
#define all(x) (x).begin(),(x).end()
#define fi first
#define se second

#define sum(a)     ( accumulate ((a).begin(), (a).end(), 0ll))
#define mine(a)    (*min_element((a).begin(), (a).end()))
#define maxe(a)    (*max_element((a).begin(), (a).end()))

typedef vector<Int> vi;
typedef pair<Int, Int> pii;
typedef pair<Int, bool> pib;
typedef pair<string, Int> psi;
typedef pair<string, string> pss;
typedef vector<pii> vpii;
typedef vector<psi> vpsi;
typedef vector<pss> vpss;


using namespace std;
// Vector
template<typename T>             istream& operator>>(istream& is,  vector<T> &v){for (auto& i : v) is >> i;        return is;}
template<typename T>             ostream& operator<<(ostream& os,  vector<T>  v){for (auto& i : v) os << i << ' '; return os;}
template <typename T>
pair<T, bool> getNthElement(set<T>& searchSet,int index)
{
    pair<T, bool> result;

    // Check if index is valid or not
    if (searchSet.size() > index) {
        result.first
                = *(std::next(
                searchSet.begin(),
                index));
        result.second = true;
    }

    else
        result.second = false;

    // Return the pair
    return result;
}


const Int N=7+1e10;

Int gcd(Int a, Int b)
{
    // Everything divides 0
    if (a == 0)
        return b;
    if (b == 0)
        return a;

    // base case
    if (a == b)
        return a;

    // a is greater
    if (a > b)
        return gcd(a-b, b);
    return gcd(a, b-a);
}

int main() {
    FAST_IO;

    Int t; cin >> t;
    while(t--){
        Int n; cin >> n;
        vi arr(n);
        cin >> arr;
        Int ans=0;
        Int Min=mine(arr);
        auto it=find(all(arr), Min);
        Int a=it-arr.begin();
        if(arr[0]==Min){
            cout << n-1 << endl;
        }
        else{
            cout << n << endl;
            cout << "1 " << a+1 << " " << Min << " " << Min+1 << "\n";
        }
        for(Int i=1;i<n;++i){
            cout << "1 " << i+1 << " " << Min << " " << Min+i << "\n";
        }
    }

    return 0;
}

