#include <bits/stdc++.h>
int a[105];
int main() {
  int n, i, ans = 0, pre = 0, flag = 0, s = 0;
  scanf("%d", &n);
  for (i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    if (a[i] < 0) ans++;
    if (ans >= 3) {
      s++;
      ans = 1;
    }
  }
  printf("%d\n", s + 1);
  ans = 0;
  for (i = 1; i <= n; i++) {
    if (a[i] < 0) ans++;
    if (ans >= 3) {
      printf("%d ", i - pre - 1);
      pre = i - 1;
      ans = 0;
      i--;
    } else if (ans < 3 && i == n)
      printf("%d", i - pre);
  }
  return 0;
}
