会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
Tony's Log
Algorithms, Distributed System, Machine Learning
博客园
::
首页
::
新随笔
::
联系
::
订阅
::
管理
::
公告
2015年9月13日
LintCode "Subtree"
摘要: A variation to Binary Tree iteration.class Solution { bool isSame(TreeNode *p1, TreeNode *p2) { if (!p1 && !p2) return true; if( (...
阅读全文
posted @ 2015-09-13 14:07 Tonix
阅读(199)
评论(0)
推荐(0)
LintCode "Minimum Subarray"
摘要: Typical solution: convert it to Maximum Array problem.And here is my solution: O(n) by using Greedy strategy on this equation: sum[i..j] = sum[0..j] -...
阅读全文
posted @ 2015-09-13 13:47 Tonix
阅读(183)
评论(0)
推荐(0)
LintCode "A + B Problem"
摘要: Using XOR on bits.class Solution {public: /* * @param a: The first integer * @param b: The second integer * @return: The sum of a and b...
阅读全文
posted @ 2015-09-13 13:00 Tonix
阅读(163)
评论(0)
推荐(0)