- 博客(4)
- 收藏
- 关注
原创 Jump Game
Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your maximum jump length at that position. Determine i
2015-05-15 17:21:12 344
原创 Subsets II
Given a collection of integers that might contain duplicates, nums, return all possible subsets. Note: Elements in a subset must be in non-descending order.The solution set must not contain du
2015-05-15 16:42:23 553
原创 Construct Binary Tree from Inorder and Postorder Traversal
这题应该算比较常见的题目了,基本的数据结构题目;递归构建每棵子树,唯一需要注意的是计算左子树的根节点在postorder的下标。 class Solution { public: //递归建树 unordered_map InMap; void BuildSubTree(vector &inorder, vector &postorder, int postInd
2015-05-15 15:33:09 407
原创 Word Search leetCode,,
Given a 2D board and a word, find if the word exists in the grid. The word can be constructed from letters of sequentially adjacent cell, where "adjacent" cells are those horizontally or vertically
2015-05-15 10:51:05 380
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人