#include <bits/stdc++.h>
using namespace std;
int a[100008];
int main() {
  int n;
  int sum = 0;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    sum = sum + a[i];
  }
  if (n == 1) {
    cout << "1 0" << endl;
    return 0;
  }
  int ss = 0;
  for (int i = 1; i <= n; i++) {
    if ((ss + a[i]) * 2 <= sum) {
      ss += a[i];
    } else {
      int k = sum - ss - a[i];
      if (k >= ss) {
        printf("%d %d\n", i, n - i);
        return 0;
      } else {
        printf("%d %d\n", i - 1, n - i + 1);
        return 0;
      }
    }
  }
}
