Var
max, count, i: integer;
a: array [1..30] of integer;
begin
max := 0;
count := 0;
for i := 1 to 30 do
read(a[i]);
for i := 1 to 30 do
begin
if a[i] < 0 then
inc(count)
else
begin
if max < count then
max := count;
count := 0;
end;
end;
if max < count then
max := count;
writeln(max);
end.