#include <bits/stdc++.h>
using namespace std;
template <class T>
ostream& operator<<(ostream& os, vector<T> V) {
  os << "[ ";
  for (auto v : V) os << v << " ";
  return os << "]";
}
template <class L, class R>
ostream& operator<<(ostream& os, pair<L, R> P) {
  return os << "(" << P.first << "," << P.second << ")";
}
long long power(long long a, long long b, long long mod) {
  long long c = 1;
  while (b > 0) {
    if (b % 2) c *= a, c %= mod;
    b /= 2;
    a *= a;
    a %= mod;
  }
  return c;
}
long long pow(long long a, long long b) {
  long long c = 1;
  while (b > 0) {
    if (b % 2) c *= a;
    b /= 2;
    a *= a;
  }
  return c;
}
const long long Mod = 1e9 + 7;
const long long N = 1e5 + 10;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cout << setprecision(25);
  long long t, x, y, k, a, b, ans;
  cin >> t;
  while (t--) {
    long long g, s, b, n;
    g = s = b = 0;
    cin >> n;
    vector<long long> arr(n, 0);
    for (int i = 0; i < n; i++) {
      cin >> arr[i];
    }
    long long end = n / 2 - 1;
    if (arr[n / 2 - 1] == arr[n / 2]) {
      for (int i = n / 2; i > 0; i--) {
        if (arr[i] != arr[i - 1]) {
          end = i - 1;
          break;
        }
      }
    }
    set<long long> se;
    int sz = 0;
    for (int i = 0; i <= end; i++) {
      se.insert(arr[i]);
      sz = se.size();
      if (sz == 1)
        g++;
      else if (sz == 2 || s <= g)
        s++;
      else
        b++;
    }
    if (sz < 3 || g >= b || g >= s) g = s = b = 0;
    cout << g << " " << s << " " << b << "\n";
  }
}
