随笔分类 -  Leetcode

上一页 1 ··· 4 5 6 7 8
摘要:算法思想:http://www.cnblogs.com/lichen782/p/leetcode_minimum_window_substring_3.html 1 public class Solution { 2 public String minWindow(String S, Str... 阅读全文
posted @ 2014-09-26 11:35 Phoebe815 阅读(192) 评论(0) 推荐(0)
摘要:Question:There are two sorted arrays A and B of size m and n respectively. Find the median of the two sorted arrays. The overall run time complexity s... 阅读全文
posted @ 2014-06-18 19:14 Phoebe815 阅读(227) 评论(0) 推荐(0)
摘要:Question:Given a binary tree, find the maximum path sum.The path may start and end at any node in the tree.For example:Given the below binary tree, ... 阅读全文
posted @ 2014-06-13 18:56 Phoebe815 阅读(146) 评论(0) 推荐(0)
摘要:Question:Given a collection of intervals, merge all overlapping intervals.For example,Given[1,3],[2,6],[8,10],[15,18],return[1,6],[8,10],[15,18].-----... 阅读全文
posted @ 2014-06-13 17:00 Phoebe815 阅读(233) 评论(0) 推荐(0)
摘要:Question:Validate if a given string is numeric.Some examples:"0"=>true" 0.1 "=>true"abc"=>false"1 a"=>false"2e10"=>trueNote:It is intended for the pro... 阅读全文
posted @ 2014-06-12 22:23 Phoebe815 阅读(828) 评论(0) 推荐(0)
摘要:Question:Given a stringsand a dictionary of wordsdict, add spaces insto construct a sentence where each word is a valid dictionary word.Return all suc... 阅读全文
posted @ 2014-06-12 15:32 Phoebe815 阅读(299) 评论(2) 推荐(0)
摘要:Question:Given a stringsand a dictionary of wordsdict, determine ifscan be segmented into a space-separated sequence of one or more dictionary words.F... 阅读全文
posted @ 2014-06-12 14:27 Phoebe815 阅读(220) 评论(0) 推荐(0)
摘要:Question:Givennnon-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in t... 阅读全文
posted @ 2014-06-12 13:20 Phoebe815 阅读(357) 评论(3) 推荐(0)

上一页 1 ··· 4 5 6 7 8