#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a;
  vector<int> v;
  while (cin >> n) {
    int x = 0;
    int t = 1;
    int i = 1;
    int cnt = 0;
    for (; i <= n; ++i) {
      cin >> a;
      if (a < 0) {
        ++x;
      }
      if (x == 3) {
        x = 1;
        v.push_back(i - t);
        t = i;
        ++cnt;
      }
    }
    if (n + 1 - t != 0) {
      v.push_back(n + 1 - t);
      ++cnt;
    }
    cout << cnt << endl;
    for (int i = 0; i < v.size() - 1; ++i) {
      cout << v[i] << ' ';
    }
    cout << v[v.size() - 1] << endl;
    v.clear();
  }
  return 0;
}
