#include <bits/stdc++.h>
using namespace std;
const int MAXN = 4e5 + 5;
int a[MAXN];
bool cmp(int x, int y) { return x > y; }
int b[MAXN], num[MAXN];
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    map<int, int> mp;
    mp.clear();
    int Max = n / 2;
    for (int i = 1; i <= n; i++) {
      cin >> a[i];
    }
    if (n < 3) {
      cout << 0 << " " << 0 << " " << 0 << endl;
      continue;
    }
    a[n + 1] = 1e6 + 7;
    int cnt = 1;
    int tot = 0;
    sort(a + 1, a + 1 + n, cmp);
    for (int i = 2; i <= n + 1; i++) {
      if (a[i] != a[i - 1]) {
        b[++tot] = a[i - 1];
        num[tot] = cnt;
        cnt = 1;
      } else
        cnt++;
    }
    int max1 = b[1], num1 = num[1];
    int max2 = -1, num2 = 0;
    int max3 = -1, num3 = 0;
    for (int i = 2; i <= tot; i++) {
      if (num2 <= num1) {
        num2 += num[i];
        continue;
      } else {
        max2 = 1;
        if (num3 <= num1) {
          num3 += num[i];
          continue;
        } else {
          break;
        }
      }
    }
    bool f = 1;
    if (num1 + num2 + num3 > Max || num1 >= num2 || num1 >= num3) f = 0;
    if (!f) {
      cout << 0 << " " << 0 << " " << 0 << endl;
    } else
      cout << num1 << " " << num2 << " " << num3 << endl;
  }
}
