摘要: Shortest PalindromeGiven a string S, you are allowed to convert it to a palindrome by adding characters in front of it. Find and return the shortest p... 阅读全文
posted @ 2015-05-23 23:09 `Liok 阅读(592) 评论(0) 推荐(0) 编辑
摘要: Kth Largest Element in an ArrayFind thekth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the ... 阅读全文
posted @ 2015-05-23 17:47 `Liok 阅读(241) 评论(0) 推荐(0) 编辑
摘要: Word LadderGiven two words (beginWordandendWord), and a dictionary, find the length of shortest transformation sequence frombeginWordtoendWord, such t... 阅读全文
posted @ 2015-05-22 14:58 `Liok 阅读(876) 评论(0) 推荐(0) 编辑
摘要: Second Highest SalaryWrite a SQL query to get the second highest salary from theEmployeetable.+----+--------+| Id | Salary |+----+--------+| 1 | 100 ... 阅读全文
posted @ 2015-05-21 01:08 `Liok 阅读(397) 评论(0) 推荐(0) 编辑
摘要: Clone GraphClone an undirected graph. Each node in the graph contains alabeland a list of itsneighbors.OJ's undirected graph serialization:Nodes are l... 阅读全文
posted @ 2015-05-20 13:20 `Liok 阅读(761) 评论(2) 推荐(0) 编辑
摘要: Merge k Sorted ListsMergeksorted linked lists and return it as one sorted list. Analyze and describe its complexity.https://leetcode.com/submissions/d... 阅读全文
posted @ 2015-05-19 14:16 `Liok 阅读(761) 评论(0) 推荐(1) 编辑
摘要: Merge Two Sorted ListsMerge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the fir... 阅读全文
posted @ 2015-05-19 13:25 `Liok 阅读(899) 评论(0) 推荐(0) 编辑
摘要: Valid SudokuDetermine if a Sudoku is valid, according to:Sudoku Puzzles - The Rules.The Sudoku board could be partially filled, where empty cells are ... 阅读全文
posted @ 2015-05-19 00:13 `Liok 阅读(424) 评论(0) 推荐(0) 编辑
摘要: Valid Palindrome Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example,"A man, a p 阅读全文
posted @ 2015-05-18 17:25 `Liok 阅读(387) 评论(0) 推荐(0) 编辑
摘要: Add Binary Given two binary strings, return their sum (also a binary string). For example,a = "11"b = "1"Return "100". https://leetcode.com/problems/a 阅读全文
posted @ 2015-05-17 21:22 `Liok 阅读(638) 评论(0) 推荐(0) 编辑