#include <bits/stdc++.h>
using namespace std;
const int maxn = 500000 + 10;
int a[maxn], cnt, sum;
int b[maxn], c[maxn];
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    int n;
    scanf("%d", &n);
    a[0] = -1;
    cnt = -1;
    sum = 0;
    for (int i = 1; i <= n; i++) {
      scanf("%d", &a[i]);
      if (a[i] != a[i - 1]) {
        cnt++;
        b[cnt] = sum;
        sum = 1;
        if (cnt) {
          c[cnt] = c[cnt - 1] + b[cnt];
        }
      } else {
        sum++;
      }
    }
    b[++cnt] = sum;
    int Max_id;
    sum = 0;
    for (int i = 1; i <= cnt; i++) {
      if (sum + b[i] > n / 2) {
        break;
      } else {
        sum += b[i];
        Max_id = i;
      }
    }
    if (n / 2 < 3 || cnt <= 3) {
      puts("0 0 0");
      continue;
    }
    bool flag = false;
    int j = Max_id;
    for (int i = 1; i <= Max_id; i++) {
      if (c[i] > c[Max_id] / 3) {
        break;
      }
      while (c[Max_id] - c[j - 1] < c[i] && j > i) j--;
      if (j == i) break;
      if (c[j - 1] - c[i] >= c[i]) {
        flag = true;
        printf("%d %d %d\n", c[i], c[j - 1] - c[i], c[Max_id] - c[j - 1]);
        break;
      }
      if (flag) break;
    }
    if (!flag) {
      puts("0 0 0");
    }
  }
  return 0;
}
