#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    vector<int> arr(n);
    for (int i = 0; i < n; ++i) cin >> arr[i];
    int l = 0, r = n / 2 - 1;
    while (r >= 0 && r + 1 < n && arr[r] == arr[r + 1]) r--;
    if (n <= 4 || r - l < 2)
      cout << "0 0 0\n";
    else {
      int val = 0;
      int g = 0, s = 0, b = 0;
      for (int x = 1; x <= r; ++x) {
        while (arr[x] == arr[l]) x++;
        int y = x;
        while (y < r) {
          while (arr[y] == arr[x]) y++;
          int golds = x - l, silvers = y - x, bronzes = r - y + 1;
          if (golds < silvers && golds < bronzes &&
              val < golds + silvers + bronzes) {
            val = golds + bronzes + silvers;
            g = golds, s = silvers, b = bronzes;
          }
          ++y;
        }
      }
      cout << g << " " << s << " " << b << '\n';
    }
  }
  return 0;
}
