#include <bits/stdc++.h>
using namespace std;
const int N = 1e5;
int a[N];
int main() {
  int num;
  scanf("%d", &num);
  while (num--) {
    int n;
    scanf("%d", &n);
    for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
    int res1 = 0, res2 = 0, temp1 = 0, temp2 = 0, len = 0, temp;
    int p1 = 1, p2 = n;
    while (p1 <= p2) {
      temp = 0;
      while (temp <= temp2 && p1 <= p2) temp += a[p1++];
      len++;
      res1 += temp;
      temp1 = temp;
      if (p1 > p2) break;
      temp = 0;
      while (temp <= temp1 && p1 <= p2) temp += a[p2--];
      len++;
      res2 += temp;
      temp2 = temp;
      if (p1 > p2) break;
    }
    printf("%d %d %d\n", len, res1, res2);
  }
  return 0;
}
