import fractions from functools import lru_cache N=int(input()) @lru_cache(maxsize=None) def A(N): if N==0: return fractions.Fraction(1) if N==1: return fractions.Fraction(1) if N>0: return A(N-1)-10*A(N-2) else: return (A(N+1)-A(N+2))/10 ans=-A(N-2) print(ans)