#include <bits/stdc++.h>
using namespace std;
int main() {
  int T;
  cin >> T;
  for (int d = 0; d < T; d++) {
    int n;
    cin >> n;
    if (n < 6) {
      int k;
      for (int i = 0; i < n; i++) {
        cin >> k;
      }
      cout << "0 0 0" << endl;
    } else {
      vector<int> a(n);
      map<int, int> m;
      for (int i = 0; i < n; i++) {
        cin >> a[i];
        m[a[i]]++;
      }
      int k1 = m[a[0]], k2 = 0, k3 = 0;
      int k = m[a[0]];
      bool flag = true;
      for (int i = 1; i < n; i++) {
        if (a[i] == a[i - 1])
          continue;
        else {
          if (flag) {
            k2 += m[a[i]];
            if (k1 < k2) flag = false;
          }
          k += m[a[i]];
          if (k > n / 2) {
            k3 = k - m[a[i]] - m[a[0]] - k2;
            break;
          }
        }
      }
      if (k1 >= k2 || k1 >= k3)
        cout << "0 0 0" << endl;
      else
        cout << k1 << " " << k2 << " " << k3 << endl;
    }
  }
  return 0;
}
