#include <bits/stdc++.h>
using namespace std;
const int maxn = 4e5 + 5;
template <class T>
inline void read(T &x) {
  x = 0;
  char c = getchar();
  T flag = 1;
  while (c < '0' || c > '9') {
    if (c == '-') flag = -1;
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = (x << 1) + (x << 3) + c - 48;
    c = getchar();
  }
  x *= flag;
}
int t;
int a[maxn], sum[maxn];
int main() {
  int t, n;
  read(t);
  while (t--) {
    read(n);
    int pre, sm = 0;
    for (int i = 1; i <= n; i++) {
      int x;
      read(x);
      a[i] = x;
    }
    pre = a[1];
    int cnt = 0, id = 0;
    for (int i = 1; i <= n; i++) {
      if (a[i] == pre) {
        cnt++;
      } else {
        id++;
        sum[id] = cnt;
        cnt = 1;
        pre = a[i];
      }
    }
    if (cnt == 1) {
      id++;
      sum[id] = cnt;
    } else {
      id++;
      sum[id] = cnt;
    }
    int s1 = 0, f = 0;
    while (s1 * 2 < n) {
      s1 += sum[id--];
    }
    int g = 0, s = 0, b = 0, t1 = 0, t2 = 0;
    if (id < 3)
      f = 1;
    else {
      s1 = n - s1;
      for (int i = 1; i <= id; i++) {
        t1 += sum[i];
        if (t1 * 3 >= s1) break;
        t2 = 0;
        for (int j = i + 1; j < id; j++) {
          t2 += sum[j];
          if (s1 - t1 - t2 <= t1) break;
          if (t2 > t1) {
            g = t1, s = t2, b = s1 - t1 - t2;
            break;
          }
        }
        if (g) break;
      }
    }
    if (f == 1)
      printf("0 0 0\n");
    else
      printf("%d %d %d\n", g, s, b);
  }
  return 0;
}
