#include <bits/stdc++.h>
using namespace std;
const long long N = 1e9 + 7;
int32_t main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  long long t;
  cin >> t;
  while (t--) {
    long long n;
    cin >> n;
    long long arr[n + 1];
    map<long long, long long> mp;
    map<long long, long long> fi;
    for (long long i = 1; i <= n; i++) {
      cin >> arr[i];
      mp[arr[i]]++;
      if (fi.count(arr[i]) == 0) fi[arr[i]] = i;
    }
    long long lim = n / 2;
    long long g = 0, s = 0;
    g = mp[arr[1]];
    if (g == n) {
      cout << "0 0 0\n";
      continue;
    }
    long long xx = 2 * (g + 1);
    if (xx > n) {
      cout << "0 0 0\n";
      continue;
    }
    s = g + 1 + mp[arr[xx]] - (xx - fi[arr[xx]]);
    long long b = 0;
    long long i = 1 + g + s;
    for (; i <= lim;) {
      long long temp = i + mp[arr[i]] - 1;
      if (temp > lim)
        break;
      else {
        b = b + mp[arr[i]];
        i = i + mp[arr[i]];
      }
    }
    if (g == 0 || s == 0 || b == 0 || g >= b || g >= s)
      cout << "0 0 0\n";
    else
      cout << g << " " << s << " " << b << "\n";
  }
}
