var
a,b:real;
i,min,max,count:integer;
begin
readln(a,b);
if (a 0) then
begin
min:=trunc(a)+1;
max:=trunc(b)
end
else if (b 0) then
begin
min:=trunc(b)+1;
max:=trunc(a)
end
else if (abegin
max:=trunc(b);
min:=trunc(a)
end
else if (bbegin
max:=trunc(a);
min:=trunc(b)
end;
for i:=min to max do
count:=count+1;
write(count)
end.