import java.util.*;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.io.Writer;
import java.math.BigInteger;
import java.util.Scanner;
import java.util.StringTokenizer;
 
public class temp {
	
	void solve() throws IOException {
		FastReader sc = new FastReader();
		int t = sc.nextInt();
		while(t-->0)
		{
			int n = sc.nextInt();
			TreeMap<Integer,Integer> tm = new TreeMap<>();
			for(int i=0;i<n;i++)
			{
				int x = sc.nextInt();
				if(tm.containsKey(x))
					tm.put(x , tm.get(x) + 1);
				else
					tm.put(x , 1);
			}
			
			if(tm.size() <= 2)
				System.out.println("0 0 0");
			else
			{
				int lk = tm.lastKey();
				int lv = tm.get(lk);
				tm.remove(lk);
				int g = lv , s = 0 , b = 0;
				
				while(!tm.isEmpty())
				{
					int key = tm.lastKey();
					int val = tm.get(key);
					tm.remove(key);
					s+=val;
					if(s > g)
						break;
				}
				
				int left = (n/2) - g - s;
				
				while(!tm.isEmpty())
				{
					int key = tm.lastKey();
					int val = tm.get(key);
					tm.remove(key);
					if((b + val) > left)
						break;
					b+=val;
				}
				
				System.out.println( g < s && g < b ? g+" "+s+" "+b : "0 0 0");
			}
		}
	}
	 
	public static void main(String[] args) throws IOException {
		// TODO Auto-generated method stub
		new temp().solve();
	}
	
	class FastReader {
		BufferedReader br;
		StringTokenizer st;
 
		public FastReader() {
			br = new BufferedReader(new InputStreamReader(System.in));
		}
 
		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;
		}
	}
}