#include <bits/stdc++.h>
using namespace std;
const int N = 4e5 + 10;
int a[N];
int sum[N];
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    for (int i = 0; i < n; ++i) {
      cin >> a[i];
    }
    vector<int> b;
    for (int i = 0, j = 0; i < n; i = j) {
      while (j < n && a[j] == a[i]) ++j;
      b.push_back(j - i);
    }
    int m = b.size();
    for (int i = 0; i < m; ++i) {
      sum[i + 1] = b[i] + sum[i];
    }
    bool f = 0;
    for (int i = m; i >= 3; --i) {
      if (sum[i] <= n / 2) {
        int p = upper_bound(sum + 2, sum + i, sum[1] * 2) - sum;
        if (p != i) {
          int g = sum[1], s = sum[p] - sum[1], b = sum[i] - sum[p];
          if (g < b) {
            f = 1;
            cout << g << ' ' << s << ' ' << b << '\n';
          }
          break;
        }
      }
    }
    if (!f) cout << "0 0 0\n";
  }
  return 0;
}
