#include <bits/stdc++.h>
using namespace std;
int n, f[200], g[200];
bool a[200];
void print(int n) {
  if (n == 0) return;
  print(n - g[n]);
  printf("%d ", g[n]);
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    int t;
    scanf("%d", &t);
    a[i] = (t >= 0);
  }
  a[0] = true;
  f[0] = 0;
  g[0] = 0;
  for (int i = 1; i <= n; i++) {
    int gg = 0;
    f[i] = 10000;
    for (int j = i; j > 0; j--) {
      gg += a[j] ? 0 : 1;
      if (gg >= 3) break;
      if (f[j - 1] + 1 <= f[i]) f[i] = f[j - 1] + 1, g[i] = i - j + 1;
    }
  }
  printf("%d\n", f[n]);
  print(n);
  return 0;
}
