#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int T;
  cin >> T;
  while (T--) {
    int N;
    cin >> N;
    long long a;
    multiset<long long> A;
    for (int i = 0; i < N; i++) {
      cin >> a;
      A.insert(a);
    }
    vector<int> n;
    while (!A.empty()) {
      auto it = --(A.end());
      n.push_back(A.count(*it));
      A.erase(*it);
    }
    if (n.size() < 3) {
      cout << 0 << " " << 0 << " " << 0 << endl;
    } else {
      int i = 0, j = 1, k = 1;
      long long sum1 = n[0];
      long long sum2 = 0;
      long long sum3 = 0;
      while (k < n.size()) {
        while (j < n.size() && sum2 <= sum1) {
          sum2 += n[j];
          sum3 -= n[j];
          j++;
        }
        while (k < n.size() && sum3 <= sum1) {
          sum3 += n[k];
          k++;
        }
        if (sum1 < sum2 && sum1 < sum3) {
          if (sum1 + sum2 + sum3 <= ((N >> 1))) {
            cout << sum1 << " " << sum2 << " " << sum3 << endl;
            break;
          } else {
            cout << 0 << " " << 0 << " " << 0 << endl;
            break;
          }
        } else if ((sum1 + sum2 + sum3 > ((N >> 1)))) {
          cout << 0 << " " << 0 << " " << 0 << endl;
          break;
        } else {
          if (i == n.size()) {
            cout << 0 << " " << 0 << " " << 0 << endl;
            break;
          } else {
            i++;
            sum1 += n[i];
            sum2 -= n[i];
          }
        }
      }
    }
  }
  return 0;
}
