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