#include <bits/stdc++.h>
using namespace std;
int a[400005];
map<int, int> s;
int main() {
  int t, n, i, j, cas = 0;
  scanf("%d", &t);
  while (t--) {
    scanf("%d", &n);
    for (i = 1; i <= n; i++) {
      scanf("%d", &a[i]);
      s[a[i]]++;
    }
    int k = n / 2;
    if (k < 3 || s[a[1]] > (k / 3))
      printf("0 0 0\n");
    else {
      int s1 = s[a[1]], s2 = 0, s3 = 0;
      if (a[k + 1] == a[k]) {
        int sum = 0;
        for (i = k; i >= 0; i--) {
          if (a[i] == a[k]) sum++;
        }
        int ans = k - sum;
        if (ans < 3)
          printf("0 0 0\n");
        else {
          int flag = -1;
          for (i = ans; i >= 0; i--) {
            if ((s3 <= s1) && (flag != a[i])) {
              s3 += s[a[i]];
              flag = a[i];
            }
            if (s3 > s1) break;
          }
          s2 = ans - s1 - s3;
          if (s2 <= s1 || s2 < 0) {
            s1 = 0;
            s2 = 0;
            s3 = 0;
          }
        }
      } else {
        int flag = -1;
        for (i = k; i >= 0; i--) {
          if ((s3 <= s1) && (flag != a[i])) {
            s3 += s[a[i]];
            flag = a[i];
          } else
            break;
        }
        s2 = k - s3 - s1;
        if (s2 <= s1 || s2 < 0) {
          s1 = 0;
          s2 = 0;
          s3 = 0;
        }
      }
      printf("%d %d %d\n", s1, s2, s3);
    }
  }
  return 0;
}
