摘要: 有点意思,比想的要难。 错误思路 from typing import List from collections import Counter import time class Solution: def jump(self, nums: List[int]) -> int: max_reach 阅读全文
posted @ 2024-07-03 19:23 夜歌乘年少 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 写了一个符和直觉的递归,时间超限了。 from typing import List import time class Solution: def canJump(self, nums: List[int]) -> bool: if len(nums) == 1: return True retu 阅读全文
posted @ 2024-07-03 14:36 夜歌乘年少 阅读(1) 评论(0) 推荐(0) 编辑