#include <bits/stdc++.h>
using namespace std;
long long t_max = 1000000007;
long long MAXX = 100000000000000000;
long long binpow(long long a, long long n, long long k) {
  long long res = 1;
  while (n)
    if (n & 1) {
      res *= a;
      res %= k;
      n--;
    } else {
      a *= a;
      a %= k;
      n >>= 1;
    }
  return res;
}
struct fab {
  int l, r;
};
bool operator<(fab n, fab m) {}
int arr[1000002];
int main() {
  int t, n, g, s, b, cnt;
  cin >> t;
  for (int u = 0; u < t; u++) {
    cin >> n;
    cnt = 0;
    int mas[n];
    vector<int> v;
    for (int i = 0; i < n; i++) {
      cin >> mas[i];
      if (v.size() == 0)
        v.push_back(mas[i]);
      else if (v[v.size() - 1] != mas[i])
        v.push_back(mas[i]);
    }
    for (int i = 0; i < n; i++) arr[mas[i]]++;
    g = 0;
    s = 0;
    b = 0;
    for (int j = 0; j < v.size(); j++) {
      int k = v[j];
      if (g == 0)
        g = arr[k];
      else {
        if (s <= g)
          s += arr[k];
        else {
          if (b <= g)
            b += arr[k];
          else {
            if (g + s + b + arr[k] <= n / 2)
              b += arr[k];
            else
              j = v.size() + 2;
          }
        }
      }
    }
    if (g + s + b <= n / 2)
      cout << g << ' ' << s << ' ' << b;
    else
      cout << 0 << ' ' << 0 << ' ' << 0;
    cout << endl;
  }
}
