摘要:
递归实现(python):# Definition for a binary tree nodeclass TreeNode: def __init__(self, x): self.val = x self.left = None self... 阅读全文
posted @ 2014-10-27 15:50
clq.lib
阅读(185)
评论(0)
推荐(0)
摘要:
典型的用栈(stack)结构解决问题的例子class Solution: def isPair(self,s1,s2): if (s1=='(' and s2==')')or (s2=='(' and s1==')'): return True ... 阅读全文
posted @ 2014-10-27 13:50
clq.lib
阅读(168)
评论(0)
推荐(0)

浙公网安备 33010602011771号