p,q=0,1
n=int(input())
if n<2:print(n)
else:
    for _ in range(n-1):p,q=q,p+q
    print(q)