This repository has been archived on 2024-12-25. You can view files and clone it, but cannot push or open issues or pull requests.
2024-03-10 20:32:51 +03:00

14 lines
235 B
ObjectPascal

program bbb;
function f(x:int64):int64; begin
if(x > 0) then Result:= 2*x-10;
if(x = 0) then Result:= 0;
if(x < 0) then Result:= 2*Abs(x)-1;
end;
begin
var input:int64;
readln(input);
writeln(f(input));
end.