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