个人博客:https://luxialan.com

上一页 1 2 3 4 5 6 ··· 11 下一页
摘要: Palindrome PartitioningGiven a strings, partitionssuch that every substring of the partition is a palindrome.Return all possible palindrome partitioni... 阅读全文
posted @ 2015-04-14 11:00 luxialan 阅读(135) 评论(0) 推荐(0) 编辑
摘要: TriangleGiven 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... 阅读全文
posted @ 2015-04-14 09:33 luxialan 阅读(167) 评论(0) 推荐(0) 编辑
摘要: Search a 2D MatrixWrite an efficient algorithm that searches for a value in anmxnmatrix. This matrix has the following properties:Integers in each row... 阅读全文
posted @ 2015-04-11 10:19 luxialan 阅读(134) 评论(0) 推荐(0) 编辑
摘要: Search for a RangeGiven a sorted array of integers, find the starting and ending position of a given target value.Your algorithm's runtime complexity ... 阅读全文
posted @ 2015-04-10 15:34 luxialan 阅读(109) 评论(0) 推荐(0) 编辑
摘要: First Missing PositiveGiven an unsorted integer array, find the first missing positive integer.For example,Given[1,2,0]return3,and[3,4,-1,1]return2.Yo... 阅读全文
posted @ 2015-04-09 17:13 luxialan 阅读(105) 评论(0) 推荐(0) 编辑
摘要: Insertion Sort ListSort a linked list using insertion sort.很简单的一道题,思路跟数组的插入排序一样/** * Definition for singly-linked list. * struct ListNode { * int ... 阅读全文
posted @ 2015-04-09 11:26 luxialan 阅读(136) 评论(0) 推荐(0) 编辑
摘要: Merge k Sorted ListsMergeksorted linked lists and return it as one sorted list. Analyze and describe its complexity./** * Definition for singly-linked... 阅读全文
posted @ 2015-04-09 09:35 luxialan 阅读(98) 评论(0) 推荐(0) 编辑
摘要: 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-04-08 21:59 luxialan 阅读(109) 评论(0) 推荐(0) 编辑
摘要: Merge Sorted ArrayGiven two sorted integer arrays A and B, merge B into A as one sorted array.Note:You may assume that A has enough space (size that i... 阅读全文
posted @ 2015-04-08 21:52 luxialan 阅读(134) 评论(0) 推荐(0) 编辑
摘要: Sum Root to Leaf NumbersGiven a binary tree containing digits from0-9only, each root-to-leaf path could represent a number.An example is the root-to-l... 阅读全文
posted @ 2015-04-04 21:25 luxialan 阅读(128) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 11 下一页