var
a:boolean;
p,new:integer;
begin
a:=TRUE;
p:=1;
while a do
readln(new);
if new >= 0
then p:= p * new
else a:=FALSE;
end;
writeln(p);
end.
var
a:boolean;
p,new:integer;
begin
a:=TRUE;
p:=1;
while a do
begin
readln(new);
if new >= 0
then p:= p * new
else a:=FALSE;
end;
writeln(p);
end.