#include <bits/stdc++.h>
using namespace std;
const long long INF = LLONG_MAX;
const long long SIZE = 4e5 + 5;
const long long mod = 1e9 + 7;
long long a[SIZE];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long t = 0, n, x, y, z, i, j, k, g, p, q, ans = 0, sum = 0, c = 0;
  string s, s1, s2;
  cin >> t;
  while (t--) {
    cin >> n;
    for (i = 1; i <= n; i++) cin >> a[i];
    set<long long> st;
    p = n / 2;
    x = a[p + 1];
    k = 0;
    for (i = p; i >= 1; i--) {
      if (a[i] != x) {
        k = i;
        break;
      }
    }
    for (i = 1; i <= k; i++) {
      st.insert(a[i]);
    }
    long long sz = st.size();
    if (sz < 3) {
      cout << "0 0 0\n";
      continue;
    }
    auto it = st.begin();
    p = *it;
    c = 0;
    for (i = 1; i <= k; i++) {
      if (a[i] == p) {
        c++;
      }
    }
    x = c;
    it++;
    p = *it;
    c = 0;
    for (i = 1; i <= k; i++) {
      if (a[i] == p) c++;
    }
    y = c;
    z = k - (x + y);
    cout << x << " " << y << " " << z << "\n";
  }
  return 0;
}
