#include <bits/stdc++.h>
using namespace std;
int main() {
  int a[105];
  int n, count = 0, countz = 0, countf = 0;
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> a[i];
  for (int i = 1; i <= n; i++) {
    count++;
    if (a[i] < 0) countf++;
    if (countf == 3) {
      countz++;
      count = countf = 1;
    }
    if (i == n) countz++;
  }
  cout << countz << endl;
  count = countz = countf = 0;
  for (int i = 1; i <= n; i++) {
    count++;
    if (a[i] < 0) countf++;
    if (countf == 3) {
      countz++;
      cout << count - 1 << " ";
      count = countf = 1;
    }
    if (i == n) cout << count << endl;
  }
  cout << endl;
  return 0;
}
