#include <bits/stdc++.h>
#define loop(n) for (int ngtkana_is_a_genius = 0; ngtkana_is_a_genius < int(n); ngtkana_is_a_genius++)
#define rep(i, begin, end) for (int i = int(begin); (i) < int(end); i++)
#define all(v) v.begin(), v.end()
#define rand(l, r) std::uniform_int_distribution<>(l, r)(mt)
using lint = long long;
auto mt = std::mt19937_64(std::random_device{}());
auto cmn = [](auto& a, auto b){ if (a > b) {a = b; return true;} return false; };
auto cmx = [](auto& a, auto b){ if (a < b) {a = b; return true;} return false; };
void debug_impl() { std::cerr << std::endl; }
template <typename Head, typename... Tail>
void debug_impl(Head head, Tail... tail) { std::cerr << " " << head; debug_impl(tail...); }
#ifndef STOPIT
#define debug(...)\
  do {\
    std::cerr << std::boolalpha << "[" << #__VA_ARGS__ << "]:";\
    debug_impl(__VA_ARGS__);\
    std::cerr << std::noboolalpha;\
  } while (false)
#else
#define debug(...) {}
#endif

template < class Container, class Value = typename Container::value_type >
auto run_length(Container const& v) {
  auto n = (int)v.size();
  if (n == 0)
    { return std::vector< std::pair< Value, int > >{}; }
  auto pos = std::vector< int >{};
  for (auto i = 1; i < n; i++) {
    if (v.at(i - 1) != v.at(i))
      { pos.emplace_back(i); }
  }
  pos.emplace_back(n);
  auto m = (int)pos.size();
  auto len = std::vector< int >(m);
  std::adjacent_difference(pos.begin(), pos.end(), len.begin());
  auto ret = std::vector< std::pair< Value, int > >(m);
  for (auto i = 0; i != m; i++)
    { ret.at(i) = {v.at(pos.at(i) - 1), len.at(i)}; }
  return ret;
}

template < std::size_t I, typename Container,
  typename Value = typename std::tuple_element_t< I, typename Container::value_type >>
inline auto project(Container const& v) {
  std::vector< Value > ret(v.size());
  std::transform(v.begin(), v.end(), ret.begin(), [](auto&& t){ return std::get< I >(t); });
  return ret;
}

template < typename Container, typename Value = typename Container::value_type, std::enable_if_t<!std::is_same< Container, std::string >::value, std::nullptr_t> = nullptr>
std::istream& operator>> (std::istream& is, Container& v)
  { for (auto & x : v) { is >> x; } return is; }

template < typename Container, typename Value = typename Container::value_type, std::enable_if_t<!std::is_same< Container, std::string >::value, std::nullptr_t> = nullptr >
std::ostream& operator<< (std::ostream& os, Container const& v) {
 os << "{";
  for (auto it = v.begin(); it != v.end(); it++)
    {os << (it != v.begin() ? "," : "") << *it;}
  return os << "}";
}

int main() {
  std::cin.tie(0); std::cin.sync_with_stdio(false);
  auto zero = [&]
  {
    std::cout << 0 << " " << 0 << " " << 0 << std::endl;
  };
  int q; std::cin >> q;
  loop(q) {
    int n; std::cin >> n;
    std::vector<int>a(n);
    std::cin>>a;
    auto rle = run_length(a);
    auto b = project<1>(rle);
    // debug(b);
    std::partial_sum(all(b), b.begin());
    b.insert(b.begin(), 0);
    int x = b.at(1);
    auto lb = std::lower_bound(b.begin(), b.end(), 2*x+1);
    if (lb == b.end()) {
      zero();
      continue;
    }
    int y = *lb;
    auto ub = std::upper_bound(all(b), n/2);
    ub--;
    if (lb >= ub) {
      zero();
      continue;
    }
    int z = *ub;
    z -= y;
    y -= x;
    std::cout << x << " " << y << " " << z << std::endl;
  }
  return 0;
}