每日一题https://leetcode-cn.com/problems/climbing-stairs/
爬楼梯,递归
class Solution(object): def climbStairs(self, n): num=[0,1,2] if(n==1): return 1 if(n==2): return 2 else: for i in range(3,n+1): num.append(num[i-1]+num[i-2]) return num[n]