#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long n;
  cin >> n;
  vector<long long> a(n);
  for (long long i = 0; i < n; i++) cin >> a[i];
  long long i = 0, j = n - 1;
  long long prev = 0, q = 0, ans = 0, x = 0, y = 0;
  while (i <= j) {
    if (q == 0) {
      long long temp = 0;
      while (i <= j and temp <= prev) {
        temp += a[i];
        i++;
      }
      ans++;
      q = 1;
      prev = temp;
      x += temp;
      continue;
    } else {
      long long temp = 0;
      while (i <= j and temp <= prev) {
        temp += a[j];
        j--;
      }
      q = 0;
      ans++;
      prev = temp;
      y += temp;
      continue;
    }
  }
  cout << ans << ' ' << x << ' ' << y << ' ' << endl;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long qu = 1;
  cin >> qu;
  for (long long cas = 1; cas <= qu; cas++) {
    solve();
  }
}
