#include <bits/stdc++.h>
using namespace std;
int main() {
  int q;
  cin >> q;
  while (q--) {
    int n, x, g = 0, s = 0, b = 0;
    cin >> n;
    map<int, int, greater<int>> mp;
    for (int i = 0; i < n; i++) {
      cin >> x;
      mp[x]++;
    }
    for (auto it = mp.begin(); it != --mp.end(); it++) {
      if (g == 0) {
        g = it->second;
      } else if (s <= g) {
        s += it->second;
      } else {
        b += it->second;
        if ((g + s + b) > n / 2) {
          b -= it->second;
          break;
        }
      }
    }
    if (g > 0 and s > 0 and b > 0 and g < s and g < b)
      cout << g << ' ' << s << ' ' << b << endl;
    else
      cout << "0 0 0\n";
  }
}
