#include <bits/stdc++.h>
using namespace std;
signed long long int ans = 0, a[100005], n, t, i = 0, m = 0, i1 = 0, i2 = 0,
                     ca = 0, cb = 0, k = 0;
signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  cin >> t;
  while (t--) {
    ans = 0;
    cin >> n;
    k = 0;
    for (i = 0; i < n; i++) {
      cin >> a[i];
      ans += a[i];
    }
    if (n == 1) {
      cout << 1 << " " << a[0] << " " << 0;
    } else {
      i = 0;
      m = 0;
      i1 = 0, i2 = 0;
      ca = 0, cb = 0;
      while (ca + cb < ans) {
        if (i1 <= i2) {
          i1 = 0;
          while (i1 <= i2) {
            i1 += a[i];
            i++;
            if (ca + cb + i1 == ans) {
              break;
            }
          }
          ca += i1;
        } else {
          i2 = 0;
          while (i2 <= i1) {
            i2 += a[n - m - 1];
            m++;
            if (ca + cb + i2 == ans) {
              break;
            }
          }
          cb += i2;
        }
        k++;
      }
      cout << k << " " << ca << " " << cb;
    }
    cout << endl;
  }
}
