码迷,mamicode.com
首页 >  
搜索关键字:实现题    ( 337个结果
leetcode 【 Maximum Subarray 】python 实现
题目:Find the contiguous subarray within an array (containing at least one number) which has the largest sum.For example, given the array[?2,1,?3,4,?1,2...
分类:编程语言   时间:2015-01-22 01:43:10    阅读次数:198
leetcode 【 Merge Sorted Array 】python 实现
题目:Given 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 is greater or eq...
分类:编程语言   时间:2015-01-21 23:53:45    阅读次数:175
leetcode 【 Rotate Image 】python 实现
题目:You are given annxn2D matrix representing an image.Rotate the image by 90 degrees (clockwise).Follow up:Could you do this in-place?代码:oj测试通过Runtime...
分类:编程语言   时间:2015-01-18 23:59:42    阅读次数:467
leetcode 【 Pascal's Triangle II 】python 实现
题目:Given an indexk, return thekthrow of the Pascal's triangle.For example, givenk= 3,Return[1,3,3,1].Note:Could you optimize your algorithm to use onl...
分类:编程语言   时间:2015-01-18 22:30:51    阅读次数:291
leetcode 【 Pascal's Triangle 】python 实现
题目:GivennumRows, generate the firstnumRowsof Pascal's triangle.For example, givennumRows= 5,Return[ [1], [1,1], [1,2,1], [1,3,3,1], [1,4,6,4...
分类:编程语言   时间:2015-01-16 23:45:10    阅读次数:2605
leetcode 【 Plus One 】python 实现
题目:Given a non-negative number represented as an array of digits, plus one to the number.The digits are stored such that the most significant digit is...
分类:编程语言   时间:2015-01-16 23:37:11    阅读次数:215
leetcode 【 Remove Duplicates from Sorted Array II 】python 实现
题目:Follow up for "Remove Duplicates":What if duplicates are allowed at mosttwice?For example,Given sorted array A =[1,1,1,2,2,3],Your function should ...
分类:编程语言   时间:2015-01-16 23:36:59    阅读次数:686
leetcode 【 Remove Duplicates from Sorted Array 】python 实现
题目:Given a sorted array, remove the duplicates in place such that each element appear onlyonceand return the new length.Do not allocate extra space fo...
分类:编程语言   时间:2015-01-16 22:14:33    阅读次数:223
leetcode 【 Remove Element 】python 实现
题目:Given an array and a value, remove all instances of that value in place and return the new length.The order of elements can be changed. It doesn't ...
分类:编程语言   时间:2015-01-16 22:14:22    阅读次数:257
leetcode 【 Add Two Numbers 】 python 实现
题目:You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a sing...
分类:编程语言   时间:2015-01-16 14:37:18    阅读次数:247
337条   上一页 1 ... 27 28 29 30 31 ... 34 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!