LeetCode Missing Number DescriptionGiven an array containing n distinct numbers taken from 0, 1, 2, …, n, find the one that is missing from the array. For example,Given nums = [0, 1, 3] return 2. Note:Your algorithm should r 8月 26 2015 #leetcode
LeetCode Binary Tree Paths DescriptionGiven a binary tree, return all root-to-leaf paths. For example, given the following binary tree: 1 / \ 2 3 \ 5 All root-to-leaf paths are: ["1->2->5", "1 8月 26 2015 #leetcode
LeetCode Ugly Number DescriptionWrite a program to check whether a given number is an ugly number. Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. For example, 6, 8 are ugly while 14 is not ugl 8月 24 2015 #leetcode
LeetCode Substring with Concatenation of All Words DescriptionYou are given a string, s, and a list of words, words, that are all of the same length. Find all starting indices of substring(s) in s that is a concatenation of each word in words exactly 8月 18 2015 #leetcode
LeeCcode: LRU Cache DescriptionDesign and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations: get and set. get(key) - Get the value (will always be positive) of the 8月 13 2015 #leetcode
LeetCode Clone Graph DescriptionClone an undirected graph. Each node in the graph contains a label and a list of its neighbors. The original problem is here. The original code is here. 8月 13 2015 #leetcode
LeetCode Word Ladder DescriptionGiven two words (beginWord and endWord), and a dictionary, find the length of shortest transformation sequence from beginWord to endWord, such that: Only one letter can be changed at a tim 8月 13 2015 #leetcode
LeetCode Unqiue Binary Search Trees 2 DescriptionGiven n, generate all structurally unique BST’s (binary search trees) that store values 1…n. For example,Given n = 3, your program should return all 5 unique BST’s shown below. 1 8月 13 2015 #leetcode
LeetCode Palindrome Partitioning DescriptionGiven a string s, partition s such that every substring of the partition is a palindrome. Return all possible palindrome partitioning of s. For example, given s = “aab”,Return [ [&quo 8月 13 2015 #leetcode
LeetCode Integer To Roman DescriptionGiven an integer, convert it to a roman numeral. Input is guaranteed to be within the range from 1 to 3999. The original problem is here. The original code is here. 8月 13 2015 #leetcode