摘要: 1、复制带随机指针的链表 class Solution(object): def copyRandomList(self, head): """ :type head: Node :rtype: Node """ if head is None: return None p = head while 阅读全文
posted @ 2019-12-22 03:11 WESWES 阅读(330) 评论(0) 推荐(0) 编辑
摘要: 1、二叉树后序遍历 class Solution(object): def postorderTraversal(self, root): """ :type root: TreeNode :rtype: List[int] """ res = [] def helper(root): if not 阅读全文
posted @ 2019-12-22 01:12 WESWES 阅读(354) 评论(0) 推荐(0) 编辑