#include <bits/stdc++.h>
using namespace std;
long long int ar[1000000], br[1000000], vis[1000009], dp[1000009], ck, n, r,
    sum, k, sm;
string st;
vector<long long int> vec;
vector<long long int> vec2[200009];
queue<long long int> qq;
stack<long long int> stk;
map<string, long long int> mp;
map<long long int, long long int> mp1;
int main() {
  long long int min1 = 9999999999;
  long long int i, j, k, e, d, t, s = 0;
  double dd, vv, gg;
  cin >> t;
  for (e = 1; e <= t; e++) {
    cin >> n;
    for (i = 1; i <= n; i++) {
      cin >> ar[i];
      mp1[ar[i]]++;
    }
    long long int base = n / 2, a = 0, b = 0, c = 0;
    if (base >= 3)
      for (i = 1; i <= n; i++) {
        long long int v = mp1[ar[i]];
        if (v == base) {
          if (a == 0) {
            a += v;
          } else if (b <= a) {
            b += v;
          } else {
            c += v;
          }
          break;
        } else if (v < base) {
          if (a == 0) {
            a += v;
          } else if (b <= a) {
            b += v;
          } else {
            c += v;
          }
          base -= v;
          i += v - 1;
        } else {
          if (a == 0) {
            a += base;
          } else if (b <= a) {
            b += base;
          } else {
            c += base;
          }
          base -= v;
          i += v - 1;
          break;
        }
      }
    cout << a << " " << b << " " << c << endl;
    mp1.clear();
  }
}
