Follow up for "Unique Paths":Now consider if some obstacles are added to the grids. How many unique paths would there be?An obstacle and empty space i... Read More
posted @ 2015-09-06 16:27 sunalive Views(127) Comments(0) Diggs(0)
Given inorder and postorder traversal of a tree, construct the binary tree.Note: 1 /** 2 * Definition for a binary tree node. 3 * struct TreeNode ... Read More
posted @ 2015-09-06 16:08 sunalive Views(131) Comments(0) Diggs(0)
1 class Solution { 2 public: 3 vector> threeSum(vector& nums) { 4 if (nums.size() > ans; 9 10 for(int i = 0;i 0 && nums[... Read More
posted @ 2015-09-06 11:22 sunalive Views(140) Comments(0) Diggs(0)