09 2015 档案

摘要:二叉树的前中后序遍历,可以用递归秒解,看起来不值一提。但如果不允许采用递归,要怎么实现呢?还是先来看看递归算法的实现吧:def visit( root): if root is not null: #1 visit(root.left) ... 阅读全文
posted @ 2015-09-07 19:51 曾可爱 阅读(255) 评论(0) 推荐(0)
摘要:Given a sorted array A with length m, we can split it into two part:{ A[0], A[1], ... , A[i - 1] } | { A[i], A[i + 1], ... , A[m - 1] }All elements in... 阅读全文
posted @ 2015-09-05 10:15 曾可爱 阅读(186) 评论(0) 推荐(0)