<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[Jilong Sun(@Uchicago)]]></title><description><![CDATA[]]></description><link>https://blog.youkuaiyun.com/sunjilong</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; sunjilong]]></copyright><item><title><![CDATA[Longest Common Prefix]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18540485</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18540485</guid><author>sunjilong</author><pubDate>Mon, 20 Jan 2014 05:20:19 +0800</pubDate><description><![CDATA[Write a function to find the longest common prefix string amongst an array of strings.
一个一个比较的方式太trivial，所以简单的用前缀树写了写。
class Node{
	char val;
	Map childs;
	public Node(){
		val = 0;
		childs = new H]]></description><category></category></item><item><title><![CDATA[Largest Rectangle in Histogram]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18359181</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18359181</guid><author>sunjilong</author><pubDate>Thu, 16 Jan 2014 15:20:41 +0800</pubDate><description><![CDATA[Given n non-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in the histogram.




Above is a histogram where width o]]></description><category></category></item><item><title><![CDATA[Subsets II]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18315435</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18315435</guid><author>sunjilong</author><pubDate>Wed, 15 Jan 2014 17:05:54 +0800</pubDate><description><![CDATA[Given a collection of integers that might contain duplicates, S, return all possible subsets.

Note:


Elements in a subset must be in non-descending order.The solution set must not contain dupli]]></description><category></category></item><item><title><![CDATA[Unique Binary Search Trees]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18311505</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18311505</guid><author>sunjilong</author><pubDate>Wed, 15 Jan 2014 15:15:30 +0800</pubDate><description><![CDATA[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.
   1         3     3      2      1
    \   ]]></description><category></category></item><item><title><![CDATA[Distinct Subsequences]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18261707</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18261707</guid><author>sunjilong</author><pubDate>Tue, 14 Jan 2014 13:55:23 +0800</pubDate><description><![CDATA[Given a string S and a string T, count the number of distinct subsequences of T in S.

A subsequence of a string is a new string which is formed from the original string by deleting some (can be non]]></description><category></category></item><item><title><![CDATA[Populating Next Right Pointers in Each Node]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18222003</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18222003</guid><author>sunjilong</author><pubDate>Mon, 13 Jan 2014 15:07:46 +0800</pubDate><description><![CDATA[Follow up for problem "Populating Next Right Pointers in Each Node".
What if the given tree could be any binary tree? Would your previous solution still work?
Note:

You may only use constant extr]]></description><category></category></item><item><title><![CDATA[Binary Tree Maximum Path Sum]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18213725</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18213725</guid><author>sunjilong</author><pubDate>Mon, 13 Jan 2014 08:44:37 +0800</pubDate><description><![CDATA[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,
       1
      / \
     2   3




Return 6.
]]></description><category></category></item><item><title><![CDATA[Valid Palindrome]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18213191</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18213191</guid><author>sunjilong</author><pubDate>Mon, 13 Jan 2014 08:01:07 +0800</pubDate><description><![CDATA[Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases.

For example,
"A man, a plan, a canal: Panama" is a palindrome.
"race a car" is not a ]]></description><category></category></item><item><title><![CDATA[Word Ladder II]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18213097</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18213097</guid><author>sunjilong</author><pubDate>Mon, 13 Jan 2014 07:51:12 +0800</pubDate><description><![CDATA[Given two words (start and end), and a dictionary, find all shortest transformation sequence(s) from start to end, such that:

Only one letter can be changed at a timeEach intermediate word must exi]]></description><category></category></item><item><title><![CDATA[Word Ladder]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18211445</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18211445</guid><author>sunjilong</author><pubDate>Mon, 13 Jan 2014 06:21:07 +0800</pubDate><description><![CDATA[Given two words (start and end), and a dictionary, find the length of shortest transformation sequence from start to end, such that:

Only one letter can be changed at a timeEach intermediate word m]]></description><category></category></item><item><title><![CDATA[Longest Consecutive Sequence]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18178121</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18178121</guid><author>sunjilong</author><pubDate>Sun, 12 Jan 2014 08:59:22 +0800</pubDate><description><![CDATA[Given an unsorted array of integers, find the length of the longest consecutive elements sequence.

For example,
Given [100, 4, 200, 1, 3, 2],
The longest consecutive elements sequence is [1, 2, 3]]></description><category></category></item><item><title><![CDATA[Surrounded Regions]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18102009</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18102009</guid><author>sunjilong</author><pubDate>Fri, 10 Jan 2014 23:48:14 +0800</pubDate><description><![CDATA[Given a 2D board containing 'X' and 'O',
 capture all regions surrounded by 'X'.

A region is captured by flipping all 'O's into 'X's
 in that surrounded region .

For example,

X X X X
X O O ]]></description><category></category></item><item><title><![CDATA[Palindrome Partitioning]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18099797</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18099797</guid><author>sunjilong</author><pubDate>Fri, 10 Jan 2014 23:03:28 +0800</pubDate><description><![CDATA[Given 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
  [
    ["aa","b"],]]></description><category></category></item><item><title><![CDATA[Palindrome Partitioning II]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18097683</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18097683</guid><author>sunjilong</author><pubDate>Fri, 10 Jan 2014 22:07:45 +0800</pubDate><description><![CDATA[Given a string s, partition s such that every substring of the partition is a palindrome.

Return the minimum cuts needed for a palindrome partitioning of s.

For example, given s = "aab",
Return]]></description><category></category></item><item><title><![CDATA[Gas Station]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18094611</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18094611</guid><author>sunjilong</author><pubDate>Fri, 10 Jan 2014 20:54:23 +0800</pubDate><description><![CDATA[There are N gas stations along a circular route, where the amount of gas at station i is gas[i].

You have a car with an unlimited gas tank and it costs cost[i] of gas
 to travel from station i to ]]></description><category></category></item><item><title><![CDATA[Candy]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18068835</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18068835</guid><author>sunjilong</author><pubDate>Fri, 10 Jan 2014 05:13:28 +0800</pubDate><description><![CDATA[There are N children standing in a line. Each child is assigned a rating value.

You are giving candies to these children subjected to the following requirements:

Each child must have at least on]]></description><category></category></item><item><title><![CDATA[Triangle]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18053989</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18053989</guid><author>sunjilong</author><pubDate>Thu, 09 Jan 2014 22:22:49 +0800</pubDate><description><![CDATA[Given a triangle, find the minimum path sum from top to bottom. Each step you may move to adjacent numbers on the row below.
For example, given the following triangle

[
     [2],
    [3,4],
   [6,]]></description><category></category></item><item><title><![CDATA[Single Number II]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18053269</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18053269</guid><author>sunjilong</author><pubDate>Thu, 09 Jan 2014 22:09:43 +0800</pubDate><description><![CDATA[Given an array of integers, every element appears three times except for one. Find that single one.

Note:
Your algorithm should have a linear runtime complexity. Could you implement it without usi]]></description><category></category></item><item><title><![CDATA[Copy List with Random Pointer]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18052907</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18052907</guid><author>sunjilong</author><pubDate>Thu, 09 Jan 2014 22:01:27 +0800</pubDate><description><![CDATA[A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null.

Return a deep copy of the list.

/**
 * Definition for singly-l]]></description><category></category></item><item><title><![CDATA[Word Break]]></title><link>https://blog.youkuaiyun.com/sunjilong/article/details/18051973</link><guid>https://blog.youkuaiyun.com/sunjilong/article/details/18051973</guid><author>sunjilong</author><pubDate>Thu, 09 Jan 2014 21:36:48 +0800</pubDate><description><![CDATA[Given a string s and a dictionary of words dict, determine if s can be segmented into a space-separated sequence of one or more dictionary words.

For example, given
s = "leetcode",
dict = ["leet"]]></description><category></category></item></channel></rss>