import fractions from functools import lru_cache @lru_cache(maxsize=None) def solve(N): if N==0: return fractions.Fraction(1,10) if N==1: return fractions.Fraction(0) if N==2: return 1-solve(N-1)-10*solve(N-2) if N>0: return -solve(N-1)-10*solve(N-2) if N<0: return (-solve(N+1)-solve(N+2))/10 N=int(input()) ans=solve(N) print(ans.numerator,"/",ans.denominator,sep="")