上一页 1 ··· 15 16 17 18 19 20 21 22 23 ··· 33 下一页
摘要: 题目: Find the contiguous subarray within an array (containing at least one number) which has the largest product. For example, given the array [2,3,-2, 阅读全文
posted @ 2015-05-09 12:13 YRB 阅读(357) 评论(0) 推荐(0) 编辑
摘要: 题目: Given an input string, reverse the string word by word. For example,Given s = "the sky is blue",return "blue is sky the". Update (2015-02-12):For 阅读全文
posted @ 2015-05-09 12:12 YRB 阅读(345) 评论(0) 推荐(0) 编辑
摘要: 题目: Evaluate the value of an arithmetic expression in Reverse Polish Notation. Valid operators are +, -, *, /. Each operand may be an integer or anoth 阅读全文
posted @ 2015-05-09 11:52 YRB 阅读(396) 评论(0) 推荐(0) 编辑
摘要: 题目: Given n points on a 2D plane, find the maximum number of points that lie on the same straight line. 链接: http://leetcode.com/problems/max-points-on 阅读全文
posted @ 2015-05-09 11:50 YRB 阅读(535) 评论(0) 推荐(0) 编辑
摘要: 题目: Sort a linked list in O(n log n) time using constant space complexity. 链接: http://leetcode.com/problems/sort-list/ 题解: Sort List, 链表排序,一看到O(nlogn) 阅读全文
posted @ 2015-05-09 11:31 YRB 阅读(628) 评论(0) 推荐(0) 编辑
摘要: 题目: Sort a linked list using insertion sort. Hide Tags Linked List Sort Sort a linked list using insertion sort. Hide Tags Linked List Sort Sort a lin 阅读全文
posted @ 2015-05-09 11:30 YRB 阅读(413) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a binary tree, return the postorder traversal of its nodes' values. For example:Given binary tree {1,#,2,3}, return [3,2,1]. Note: Recursive 阅读全文
posted @ 2015-05-09 11:27 YRB 阅读(622) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a binary tree, return the preorder traversal of its nodes' values. For example:Given binary tree {1,#,2,3}, 1 \ 2 / 3 return [1,2,3]. Note:  阅读全文
posted @ 2015-05-07 04:05 YRB 阅读(562) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a singly linked list L: L0→L1→…→Ln-1→Ln,reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→… You must do this in-place without altering the nodes' values. 阅读全文
posted @ 2015-04-19 12:37 YRB 阅读(526) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a linked list, return the node where the cycle begins. If there is no cycle, return null. Follow up:Can you solve it without using extra spa 阅读全文
posted @ 2015-04-19 11:23 YRB 阅读(494) 评论(0) 推荐(0) 编辑
上一页 1 ··· 15 16 17 18 19 20 21 22 23 ··· 33 下一页