#include <bits/stdc++.h>
using namespace std;
long long dr[] = {-1, 1, 0, 0};
long long dc[] = {0, 0, 1, -1};
long long gcd(long long a, long long b);
long long exp(long long x, long long y, long long p);
long long exp(long long x, long long y);
void InverseofNumber();
void InverseofFactorial();
void factorial();
long long Binomial(long long n, long long R);
long long factorialNumInverse[((long long)3e5 + 20) + 1];
long long naturalNumInverse[((long long)3e5 + 20) + 1];
long long fact[((long long)3e5 + 20) + 1];
void fileIO() {}
int main() {
  clock_t start, end;
  start = clock();
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long t;
  cin >> t;
  while (t--) {
    long long n;
    cin >> n;
    long long a[n];
    for (long long i = 0; i < n; i++) cin >> a[i];
    if (n < 5) {
      cout << "0 0 0"
           << "\n";
      continue;
    }
    long long qq = n;
    long long kk = n / 2 - 1;
    while (a[n / 2] == a[kk] && kk >= 0) {
      kk--;
    }
    n = kk;
    n++;
    if (qq & 1) n++;
    long long g = 1;
    long long i;
    for (i = 1; i < n; i++) {
      if (a[0] == a[i]) {
        g++;
      } else
        break;
    }
    long long j;
    long long b = 1;
    if (i != n - 1) {
      for (j = n - 2; j >= i; j--) {
        if (a[n - 1] == a[j])
          b++;
        else
          break;
      }
      if (b > g) {
        long long s = (j - i + 1);
        if (s > g) {
          cout << g << " " << s << " " << b << "\n";
        } else {
          cout << "0 0 0"
               << "\n";
        }
      } else {
        if (j > i) {
          long long w = a[j];
          j--;
          b++;
          for (; j > i; j--) {
            if (w == a[j]) {
              b++;
            } else
              break;
          }
          long long s = (j - i + 1);
          if (s > g && b > g) {
            cout << g << " " << s << " " << b << "\n";
          } else {
            cout << "0 0 0"
                 << "\n";
          }
        } else {
          cout << "0 0 0"
               << "\n";
        }
      }
    } else {
      cout << "0 0 0"
           << "\n";
    }
  }
  end = clock();
  double timeTaken =
      (double(end - start) * (double(1000))) / double(CLOCKS_PER_SEC);
  cerr << "timeTaken"
       << "=" << timeTaken << "\n";
  return 0;
}
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long exp(long long x, long long y, long long p) {
  long long res = 1;
  while (y) {
    if (y % 2) res = (res * x % p) % p;
    x = (x * x) % p;
    y /= 2;
  }
  return res;
}
long long exp(long long x, long long y) {
  long long res = 1;
  while (y) {
    if (y % 2) res = (res * x);
    x = (x * x);
    y /= 2;
  }
  return res;
}
void InverseofNumber() {
  naturalNumInverse[0] = naturalNumInverse[1] = 1;
  for (long long i = 2; i <= ((long long)3e5 + 20); i++)
    naturalNumInverse[i] = naturalNumInverse[((long long)1e9 + 7) % i] *
                           (((long long)1e9 + 7) - ((long long)1e9 + 7) / i) %
                           ((long long)1e9 + 7);
}
void InverseofFactorial() {
  factorialNumInverse[0] = factorialNumInverse[1] = 1;
  for (long long i = 2; i <= ((long long)3e5 + 20); i++)
    factorialNumInverse[i] =
        (naturalNumInverse[i] * factorialNumInverse[i - 1]) %
        ((long long)1e9 + 7);
}
void factorial() {
  fact[0] = 1;
  for (long long i = 1; i <= ((long long)3e5 + 20); i++)
    fact[i] = (fact[i - 1] * i);
}
long long Binomial(long long n, long long R) {
  long long ans = ((fact[n] * factorialNumInverse[R]) % ((long long)1e9 + 7) *
                   (factorialNumInverse[n - R]) % ((long long)1e9 + 7)) %
                  ((long long)1e9 + 7);
  return ans;
}
