随笔分类 -  LeetCode

上一页 1 ··· 57 58 59 60 61
摘要:Suppose an array sorted in ascending order is rotated at some pivot unknown to you beforehand. (i.e., [0,1,2,4,5,6,7] might become [4,5,6,7,0,1,2]). F 阅读全文
posted @ 2014-10-21 15:15 Grandyang 阅读(11245) 评论(4) 推荐(0) 编辑
摘要:Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum. N 阅读全文
posted @ 2014-10-20 13:08 Grandyang 阅读(17944) 评论(4) 推荐(0) 编辑
摘要:Suppose an array of length n sorted in ascending order is rotated between 1 and n times. For example, the array nums = [0,1,2,4,5,6,7] might become: [ 阅读全文
posted @ 2014-10-18 13:05 Grandyang 阅读(16813) 评论(14) 推荐(1) 编辑
摘要:Given a non-negative integer numRows, generate the first numRows of Pascal's triangle. In Pascal's triangle, each number is the sum of the two numbers 阅读全文
posted @ 2014-10-18 04:17 Grandyang 阅读(9911) 评论(2) 推荐(2) 编辑
摘要:Given a non-negative index k where k ≤ 33, return the kth index row of the Pascal's triangle. Note that the row index starts from 0. In Pascal's trian 阅读全文
posted @ 2014-10-17 16:52 Grandyang 阅读(12826) 评论(2) 推荐(0) 编辑
摘要:Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example, "A man, a plan, a canal: Pa 阅读全文
posted @ 2014-10-17 04:09 Grandyang 阅读(21680) 评论(5) 推荐(3) 编辑
摘要:Given an integer array nums, find the contiguous subarray within an array (containing at least one number) which has the largest product. Example 1: E 阅读全文
posted @ 2014-10-16 14:24 Grandyang 阅读(27059) 评论(4) 推荐(2) 编辑

上一页 1 ··· 57 58 59 60 61
Fork me on GitHub