标签:solution info def lis list tmp 提交 style etc
提交:O(N)
class Solution: def destCity(self, paths: List[List[str]]) -> str: dic = {} for i,v in paths: dic[i] = v tmp = paths[0][1] while tmp in dic: tmp = dic[tmp] return tmp
标签:solution info def lis list tmp 提交 style etc
原文地址:https://www.cnblogs.com/oldby/p/12823342.html