N = int(input()) dp = [0 for _ in range(N+1)] def rec(i): if not dp[i] == 0: return dp[i] else: if i >= 2: dp[i] = rec(i-1) + rec(i-2) elif i == 1: dp[i] = rec(i-1) elif i == 0: dp[i] = 1 else: raise ValueError("No such value") return dp[i] print(rec(N))