# N阶楼梯上楼梯问题# 动态规划法求解
steps =[1]*100for i inrange(2,100):
steps[i]= steps[i-1]+ steps[i-2]if __name__ =='__main__':try:whileTrue:
n =int(input())print(steps[n])except EOFError:pass
# N阶楼梯上楼梯问题# 动态规划法求解,使用缓存技术defgetStepNum(n):if n <3:return n
else:return getStepNum(n-2)+ getStepNum(n-1)if __name__ =='__main__':try:whileTrue:
n =int(input())print(getStepNum(n))except EOFError:pass
# N阶楼梯上楼梯问题# 动态规划法求解,使用缓存技术import functools
@functools.lru_cache(maxsize=100)defgetStepNum(n):if n <3:return n
else:return getStepNum(n-2)+ getStepNum(n-1)if __name__ =='__main__':try:whileTrue:
n =int(input())print(getStepNum(n))except EOFError:pass