def num(n): a = 2 b = 3 if n == 1: return a elif n == 2: return b else: return num(n-1)+num(n-2) n = int(input()) print(num(n))