Python刷leetcode--剑指 Offer 10- II.青蛙跳台阶问题
思路:先递归,再优化递归。拖慢递归的原因是重复的底层计算。所以计算过一次就存起来。每次计算就判断是不是已经计算过了class Solution: def __init__(self): self.val = {} self.count = 0 def numWays(self, n: int) -> int: # leetcode submit region end(Prohibit modification and delet