摘要:
455.分发饼干 1、优先大饼干 class Solution: def findContentChildren(self, g: List[int], s: List[int]) -> int: g.sort() s.sort() index = len(s) - 1 # 最后一块饼干 res = 阅读全文
posted @ 2023-11-10 21:08
忆象峰飞
阅读(16)
评论(0)
推荐(0)
摘要:
332.重新安排行程 方法一和方法二在力扣用例会超时 方法一、 class Solution: def findItinerary(self, tickets: List[List[str]]) -> List[str]: tickets.sort() res = [] used = [False] 阅读全文
posted @ 2023-11-10 00:16
忆象峰飞
阅读(27)
评论(0)
推荐(0)