摘要:
Given n, how many structurally unique BST’s (binary search trees) that store values 1…n? For example, Given n = 3, there are a total of 5 unique BST’s 阅读全文
摘要:
Given an integer n, generate all structurally unique BST’s (binary search trees) that store values 1…n. For example, Given n = 3, your program should 阅读全文
摘要:
Given a m x n grid filled with non negative numbers, find a path from top left to bottom right which minimizes the sum of all numbers along its path. 阅读全文
摘要:
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 阅读全文
摘要:
Given an input string (s) and a pattern (p), implement regular expression matching with support for '.' and ' '. The matching should cover the entire 阅读全文
摘要:
Given a string s, find the longest palindromic substring in s. You may assume that the maximum length of s is 1000. Example 1: Example 2: "cbbd" "bb" 阅读全文