#include <bits/stdc++.h>
using namespace std;
void solve() {
  int n;
  cin >> n;
  int countNegatives = 0;
  int countPositives = 0;
  int k;
  int numbers[n];
  for (int i = 0; i < n; i++) {
    cin >> k;
    numbers[i] = k;
    if (k < 0) {
      countNegatives++;
    }
  }
  int reports;
  if (countNegatives % 2 == 0) {
    reports = countNegatives / 2;
  } else {
    reports = (countNegatives + 1) / 2;
  }
  if (reports == 0) {
    reports++;
  }
  cout << reports << "\n";
  int cMinus = 0;
  int counter = 0;
  int i = 0;
  while (i < n) {
    counter++;
    if (numbers[i] < 0) {
      cMinus++;
    }
    if (cMinus == 3) {
      cout << counter - 1 << " ";
      cMinus = 0;
      counter = 0;
      i--;
    }
    i++;
  }
  if (counter) {
    cout << counter;
  }
  cout << "\n";
}
int main() {
  std::ios_base::sync_with_stdio(false);
  cin.tie(0);
  int t = 1;
  while (t--) {
    solve();
  }
  return 0;
}
