#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    int arr[n];
    map<int, int> m;
    for (int i = 0; i < n; i++) {
      cin >> arr[i];
      m[arr[i]]++;
    }
    int d[3] = {0};
    int a = 0;
    int b = arr[0];
    d[a] = m[arr[0]];
    int sum = 0;
    for (int i = 0; i < n / 2; i++) {
      if (b == arr[i]) {
        sum++;
      } else if ((b != arr[i] && a == 0) ||
                 (b != arr[i] && d[1] > d[0] && a == 1)) {
        a++;
        sum++;
        d[a] = m[arr[i]];
        b = arr[i];
      } else if (b != arr[i] && d[1] <= d[0]) {
        d[a] += m[arr[i]];
        b = arr[i];
        sum++;
      } else if (a == 2) {
        d[a] += m[arr[i]];
        b = arr[i];
        sum++;
      }
    }
    if (arr[n / 2 - 1] == arr[n / 2]) d[2] -= m[arr[n / 2 - 1]];
    if (d[0] < d[1] && d[0] < d[2])
      cout << d[0] << " " << d[1] << " " << d[2] << endl;
    else
      cout << 0 << " " << 0 << " " << 0 << endl;
  }
  return 0;
}
