Artificial intelligent assistant

Is it possible to unify these two expressions into one? I have the following expressions $\forall n \in \Bbb N$: $E = f(n)-1$ if $n \gt 1$ $E = f(n)+1$ if $n = 0$ I would like to have only one expression like this: $E = f(n)+$(some nice notation able to unify both cases into one) > Is there a notation able to unify the expressions into one? $n=0$ is an special case. Initially I do not think it is possible but there might be a notation capable of doing it and I do not see it. Thank you!

$E = f(n) + \dfrac{|n - 1/2|}{1/2 - n}$

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 1941c442464569cafba3e947b422cd12