 #include<bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
    #define pb push_back
    #define sz(a) ll((a).size())
    #define   pr  pair<ll,ll>
    #define all(c) (c).begin(),(c).end()
    #define tr(c,i) for(typeof((c).begin() i = (c).begin(); i != (c).end(); i++)
    #define SIZE 100002
    #define fi first
    #define se  second
    #define vi vector<ll>
    #define hell  1000000000+7
#define ordered_set tree<int, null_type,less_equal<int>, rb_tree_tag,tree_order_statistics_node_update> 
    #define MAXN 1000000+1000
  //  #define M_PI      3.14159265358979323846
    using namespace std;
 
      typedef  long long int ll ;
   
   using namespace __gnu_pbds; 
  

    void machayenge(){
     ll t; cin>>t;
     while(t--){
      ll n; cin>>n;
      ll arr[n];
      map<ll,ll> co;
      ll m=0;
      for(ll i=0;i<n;++i){
        cin>>arr[i];
        m=max(m,arr[i]);
        co[arr[i]]++;
      }
      ll con=0;
     ll dd=0;
     ll g=0,b=0,s=0;
     ll in=1;
     bool flag=true;
     for(auto i: co){
        if(con>=(n+1)/2){
          if(co.size()-dd < 3){flag=false;break;}
          if(in==co.size()) g+=i.se;
          else if(in== co.size()-1) s+=i.se;
          else b+=i.se;
        }
       else  dd++;
       in++;
      con+=i.se;

     }
     if(flag==false) cout<<0<<" "<<0<<" "<<0<<"\n";
     else cout<<g<<" "<<s<<" "<<b<<"\n";



     }


   }
 
    int main(){
     ios_base::sync_with_stdio(false);
       cin.tie(NULL);
          cout.tie(0);
 
//    cout<<5%3;   
 machayenge();
 
    return 0;} 