Pascal :
var x:integer; begin readln(x); if x>0 then writeln(x+1) else if x=0 then writeln(0) else writeln(x-1); end.
By signing up a 算道OJ universal account, you can submit code and join discussions in all online judging services provided by us.
Using your 算道OJ universal account