import sys L = int(input()) if L == 2: print(3) print("INF") sys.exit() def F(n): x, y = 1, 0 a, b, c, d = 1, 1, 1, 0 while n > 0: if n % 2 == 1: x, y = a * x + b * y, c * x + d * y bc = b * c a, b, c, d = a * a + bc, b * (a + d), c * (a + d), bc + d * d n //= 2 return y way = F(L) if L % 2 == 0: way -= F(L // 2) ** 2 print(L) print(way)