#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    int p[1000001];
    memset(p, 0, sizeof(p));
    map<int, int> m;
    vector<int> a;
    for (int i = 0; i < n; i++) {
      int x;
      cin >> x;
      p[x]++;
      if (m[x] == 0) {
        a.push_back(x);
        m[x]++;
      }
    }
    if (n < 3) {
      cout << "0 0 0"
           << "\n";
      continue;
    }
    int g = 0, s = 0, b = 0;
    int total = 0;
    g += p[a[0]];
    total += p[a[0]];
    int i = 1;
    for (; i < a.size() - 1; i++) {
      if (total + p[a[i]] + p[a[i + 1]] <= n / 2) {
        s += p[a[i]];
        total += p[a[i]];
      } else {
        break;
      }
    }
    for (; i < a.size(); i++) {
      if (total + p[a[i]] > n / 2) break;
      b += p[a[i]];
      total += p[a[i]];
    }
    if (total > n / 2 || s == 0 || b == 0) {
      cout << "0 0 0"
           << "\n";
    } else {
      cout << g << " " << s << " " << b << "\n";
    }
  }
  return 0;
}
