#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, time[1000001], totalTime[1000001];
  cin >> n;
  totalTime[0] = 0;
  for (int i = 1; i <= n; i++) {
    cin >> time[i];
    totalTime[i] = totalTime[i - 1] + time[i];
  }
  if (n == 1)
    cout << 1 << ' ' << 0 << endl;
  else {
    int pointer = 1;
    while (totalTime[pointer] < totalTime[n] - totalTime[pointer]) pointer++;
    if (totalTime[pointer] == totalTime[n] - totalTime[pointer])
      cout << pointer << ' ' << n - pointer << endl;
    else {
      int Alice = totalTime[pointer - 1];
      int Bob = pointer;
      while (!(totalTime[n] - totalTime[Bob - 1] >= Alice &&
               totalTime[n] - totalTime[Bob] < Alice)) {
        Bob++;
        if (Bob > n) break;
      }
      if (Bob > n) {
        cout << 1 << ' ' << n - 1 << endl;
        return 0;
      }
      if (Bob == pointer)
        cout << pointer - 1 << ' ' << n - pointer + 1 << endl;
      else
        cout << pointer << ' ' << n - pointer << endl;
    }
  }
  return 0;
}
