摘要: 1.Minimum Depth of Binary Tree 2.Maximum Depth of Binary Tree 3.Path Sum 4.Path Sum II 5.Binary Tree Maximum Path Sum 6、给一棵二叉树, 找到和为最小的子树, 返回其根节点。 7、求 阅读全文
posted @ 2019-09-26 23:33 知是行之始,行是知之成 阅读(242) 评论(0) 推荐(0) 编辑
摘要: 题目描述 用两个栈来实现一个队列,完成队列的Push和Pop操作。 队列中的元素为int类型。 class Queue(object): def __init__(self): self.stack_a = [] self.stack_b = [] def push(self, node): sel 阅读全文
posted @ 2019-09-26 00:21 知是行之始,行是知之成 阅读(123) 评论(0) 推荐(0) 编辑